Photographing Method and Terminal

ABSTRACT

A terminal includes a camera and a sensor, where the sensor is configured to detect a status of holding the terminal by a user; the terminal displays a first interface, and displays a first photographing control on the first interface in response to detecting that a current status of holding the terminal by the user undergoes a change satisfying a preset condition, where the first interface is not a viewfinder interface of the terminal; and the terminal displays a second interface in response to an operation of the user on the first photographing control, where the second interface is a viewfinder interface of the terminal.

CROSS-REFERENCE TO RELATED APPLICATIONS

This application is a National Stage of International Patent ApplicationNo. PCT/CN2017/112722 filed on Nov. 23, 2017, which is herebyincorporated by reference in its entirety.

TECHNICAL FIELD

This application relates to the field of electronic technologies, and inparticular, to a photographing method and a terminal.

BACKGROUND

With the progress of society and improvement of people's livingstandard, more people choose to use photographs to record details oflife. For example, a user may tap a “Camera” application icon on a homescreen of a mobile phone to control the mobile phone to turn on a cameraand display a photographing interface.

When the mobile phone currently displays an interface of anotherapplication (for example, WeChat), the user needs to control the mobilephone to exit the currently displayed application interface and displaythe home screen of the mobile phone, and then taps the “Camera”application icon on the home screen of the mobile phone to control themobile phone to turn on the camera and display the photographinginterface. User operations such as controlling the mobile phone to exitthe current application interface and return to the home screen of themobile phone and then tapping the “Camera” application icon to start the“Camera” application are complex, and human-machine interactionperformance is relatively poor.

SUMMARY

This application provides a photographing method and a terminal, tosimplify user operations for starting a “Camera” application on theterminal, improve human-machine interaction performance of the terminal,and further improve user experience.

According to a first aspect, this application provides a photographingmethod, which may be applied to a terminal including a camera and one ormore sensors, where the one or more sensors are configured to detect astatus of holding the terminal by a user, and the photographing methodincludes: displaying, by the terminal, a first interface, and displayinga first photographing control on the first interface in response todetecting that a current status of holding the terminal by the userundergoes a change satisfying a preset condition, where the firstinterface is not a viewfinder interface of the terminal; and displayinga second interface on the terminal in response to an operation of theuser on the first photographing control, where the second interface is aviewfinder interface of the terminal.

When the terminal displays the first interface (that is, an interfacewhen the terminal is in a screen-on state), and detects that the statusof holding the terminal by the user undergoes the change satisfying thepreset condition, the terminal displays, on the first interface, thephotographing control used to turn on the camera, so that the user canoperate the photographing control to start a “Camera” application forphotographing. When the terminal displays the first interface, andautomatically detects that the status of holding the terminal by theuser undergoes the change satisfying the preset condition, the terminaldisplays, on the first interface, the photographing control used to turnon the camera, so that the user can operate the photographing control tostart the “Camera” application for photographing. This can simplify useroperations for starting the “Camera” application on the terminal,improve human-machine interaction performance of the terminal, andfurther improve user experience.

It may be understood that, the user may want to record some fleetingimages, but in a process in which the terminal displays the firstinterface and displays the second interface after interacting with theuser, the images that the user wants to shoot possibly no longer exist,and user experience is affected.

On this basis, in a possible design, when the terminal displays thefirst interface, the terminal may turn on the camera in the terminal inresponse to detecting that the current status of holding the terminal bythe user undergoes the change satisfying the preset condition, tocapture a preview image by using the camera.

In this design, when the terminal displays the first photographingcontrol on the first interface, even if the terminal turns on the camerato capture the preview image, a viewfinder frame of the camera is notdisplayed on the first interface, that is, the first interface is not aviewfinder interface of the terminal. In other words, even if theterminal has turned on the camera for viewfinder setting andphotographing, because the terminal does not display the viewfinderinterface, the user cannot see, on a display screen of the terminal, theimage captured or taken by the terminal by using the camera.

In another possible design, the terminal may turn on the camera whendisplaying the first photographing control on the first interface.Because the terminal has turned on the camera when displaying the firstinterface, and has captured the preview image by using the camera, theterminal may save, in response to the operation of the user on the firstphotographing control on the first interface, a first image obtainedbased on the preview image, and display the second interface.

Specifically, the displaying a second interface on the terminal inresponse to an operation of the user on the first photographing controlincludes: saving, in the terminal in response to a first operation ofthe user on the first photographing control, a first image obtainedbased on the preview image, and displaying the second interface on theterminal. The first operation may be a tap operation, a touch and holdoperation, a double-tap operation, a slide-up operation, or a slide-downoperation.

Optionally, when the first operation is a different operation, the firstimage may be different image content. For example, when the firstoperation is a slide-up operation of the user on the first photographingcontrol, the first image saved by the terminal may be an image whosedefinition is the highest in the preview images captured by the camera;or when the first operation is a slide-down operation of the user on thefirst photographing control, the first image saved by the terminal maybe a video image including a plurality of preview images captured by thecamera.

In another possible design, the one or more sensors may determine, bydetecting that the terminal is rotated, or that the terminal movesforward relatively to the user, or that the terminal moves upwardrelatively to a horizontal line, whether the status of holding theterminal by the user undergoes the change satisfying the presetcondition.

Specifically, the terminal may detect a motion parameter of theterminal; then determine, based on the motion parameter, whether theterminal is rotated, or whether the terminal moves forward relatively tothe user, or whether the terminal moves upward relatively to thehorizontal line; and finally determine, based on a determining result,whether the status of holding the terminal by the user undergoes thechange satisfying the preset condition. For example, when the motionparameter detected by the sensor in the terminal indicates that theterminal is “rotated”, “moving forward”, and “moving upward”, the firstphotographing control may be normally displayed; or when the motionparameter detected by the sensor in the terminal indicates that theterminal is “rotated”, “moving forward”, and “moving upward, but anupward amplitude is insufficient”, the first photographing control maybe normally displayed but is relatively small, and transparency of thefirst photographing control is relatively high.

In another possible design, that a current status of holding theterminal by the user undergoes a change satisfying a preset conditionspecifically includes: an included angle between a display screen of theterminal and a horizontal screen is within a preset range after the oneor more sensors detect that the terminal is rotated and moves upward.

In another possible design, when the operation (that is, a secondoperation) of the user on the first photographing control may be adifferent user operation such as a tap operation, a double-tapoperation, or a touch and hold operation, the second interface may alsobe a photographing interface in a different photographing mode of theterminal. To be specific, the second interface is a photographinginterface of the terminal in a photographing mode corresponding to thesecond operation. Photographing modes of the terminal may include atleast a photographing mode using a rear-facing camera, aself-photographing mode, a panoramic mode, and a video mode.Specifically, the displaying a second interface on the terminal inresponse to an operation of the user on the first photographing controlmay include: displaying, on the terminal in response to a secondoperation of the user on the first photographing control, a viewfinderinterface in a photographing mode corresponding to the second operation.

The terminal may display viewfinder interfaces in differentphotographing modes in response to different operations of the user onthe first photographing control. Therefore, the user can control, byperforming different operations on the first photographing control, theterminal to directly display a corresponding viewfinder interface, anddoes not need to control the terminal to switch between photographingmodes after controlling the terminal to display the viewfinder interfacefor photographing by the rear-facing camera.

In another possible design, the second interface includes a secondphotographing control. After the displaying a second interface on theterminal in response to an operation of the user on the firstphotographing control, the method in this application further includes:saving, in the terminal in response to a third operation of the user onthe second photographing control, an image captured by the camera inresponse to the third operation.

Optionally, to facilitate user operations, when a left hand of the userholds the terminal, the terminal may display the second photographingcontrol in a high-frequency touch area on a left side of the secondinterface, or when a right hand of the user holds the terminal, theterminal may display the second photographing control in ahigh-frequency touch area on a right side of the second interface.

In this application, the terminal may display, on the second interface,the second photographing control used to control the terminal to performphotographing, and the second photographing control may be displayed onone side on which the user holds the terminal, so that the user canoperate the second photographing control more conveniently andcomfortably. This can avoid a problem that a single hand of the usercannot conveniently tap a shutter of the terminal for photographing whena touchscreen of the terminal is relatively large, and can improve userexperience.

In another possible design, after the displaying a second interface onthe terminal in response to an operation of the user on the firstphotographing control, the method in this application further includes:displaying a third interface on the terminal in response to a fourthoperation of the user on the second photographing control, where thefourth operation is used to instruct the terminal to switch betweenphotographing modes of the terminal, the third interface is a viewfinderinterface of the terminal in a photographing mode corresponding to thefourth operation, and the fourth operation is different from the thirdoperation.

The terminal may switch between the photographing modes of the terminalin response to the fourth operation of the user on the secondphotographing control. This improves efficiency of switching between thephotographing modes of the terminal by the user, and improves userexperience.

In another possible design, display positions of the first photographingcontrol and the second photographing control on the display screen ofthe terminal are the same.

In another possible design, the terminal may display, in a floatingmanner, the first photographing control on the first interface displayedby the terminal. Therefore, the terminal can display, on the firstinterface in response to a moving operation of the user on the firstphotographing control, dynamic images of the first photographing controlthat dynamically moves along a moving track of the moving operation.

In another possible design, after the terminal displays the firstinterface including the first photographing control, if the terminaldoes not receive the first operation of the user on the firstphotographing control within a preset time, it indicates that anoperation of holding the terminal by the user may be an unintentionaloperation of the user. To prevent the terminal from displaying the firstphotographing control on the first interface due to an unintentionaloperation of the user, the terminal may display the first photographingcontrol that gradually scales down, until the first photographingcontrol is not displayed. Specifically, the method in this applicationmay further include: after the displaying, in a floating manner, thefirst photographing control on the first interface displayed by theterminal, if no operation on the floating first photographing control isdetected within a preset time, no longer displaying the firstphotographing control on the first interface.

In another possible design, the displaying, by the terminal whendisplaying a first interface, a first photographing control on the firstinterface in response to detecting that a current status of holding theterminal by the user undergoes a change satisfying a preset conditionincludes: when the terminal displays the first interface, displaying, bythe terminal, the first photographing control on a left side of thefirst interface in the floating manner in response to detecting that theterminal is currently held by the left hand of the user, or displayingthe first photographing control on a right side of the first interfacein the floating manner in response to detecting that the terminal iscurrently held by the right hand of the user.

The terminal may display the first photographing control on the leftside of the first interface when the left hand of the user holds theterminal, or display the first photographing control on the right sideof the first interface when the right hand of the user holds theterminal, so that the user can operate the first photographing controlmore conveniently and comfortably, and user experience can be improved.

In another possible design, before the displaying a first photographingcontrol on the first interface of the terminal, the method in thisapplication further includes: detecting that the camera is in an offstate. To be specific, the first photographing control is displayed onthe first interface only when the camera is in the off state. If thecamera is in an on state (for example, when the terminal turns on thecamera for photographing), even if the terminal detects that the currentstatus of holding the terminal by the user undergoes the changesatisfying the preset condition, the terminal does not display the firstphotographing control.

According to a second aspect, this application provides a terminal, theterminal includes a camera and one or more sensors, and the terminalincludes a detection unit and a display unit. The detection unit isconfigured to detect, by using the one or more sensors, a status ofholding the terminal by a user; and the display unit is configured to:display a first interface; display a first photographing control on thefirst interface in response to detecting, by the detection unit, that acurrent status of holding the terminal by the user undergoes a changesatisfying a preset condition, where the first interface is not aviewfinder interface of the terminal; and display a second interface inresponse to an operation of the user on the first photographing control,where the second interface is a viewfinder interface of the terminal.

In a possible design, the terminal further includes a turn-on unit,where the turn-on unit is configured to: when the terminal displays thefirst interface, turn on the camera in response to detecting, by thedetection unit, that the current status of holding the terminal by theuser undergoes the change satisfying the preset condition, to capture apreview image by using the camera.

In another possible design, the terminal further includes a storageunit, where the storage unit is configured to save, in response to afirst operation of the user on the first photographing control, a firstimage obtained based on the preview image.

In another possible design, that a current status of holding theterminal by the user undergoes a change satisfying a preset conditionspecifically includes: an included angle between the display unit and ahorizontal screen is within a preset range after the detection unitdetects, by using the sensor, that the terminal is rotated and movesupward.

In another possible design, that the display unit is configured todisplay a second interface on the terminal in response to an operationof the user on the first photographing control includes: the displayunit is configured to display, in response to a second operation of theuser on the first photographing control, a viewfinder interface in aphotographing mode corresponding to the second operation, where thephotographing mode corresponding to the second operation is any one of aphotographing mode using a rear-facing camera, a self-photographingmode, a panoramic mode, and a video recording mode.

In another possible design, the second interface includes a secondphotographing control; and after the display unit displays the secondinterface on the terminal in response to the operation of the user onthe first photographing control, the storage unit is configured to save,in response to a third operation of the user on the second photographingcontrol, an image captured by the camera in response to the thirdoperation.

In another possible design, after displaying the second interface on theterminal in response to the operation of the user on the firstphotographing control, the display unit is further configured to displaya third interface on the terminal in response to a fourth operation ofthe user on the second photographing control, where the fourth operationis used to instruct the terminal to switch between photographing modesof the terminal, the third interface is a viewfinder interface of theterminal in a photographing mode corresponding to the fourth operation,and the fourth operation is different from the third operation.

In another possible design, display positions of the first photographingcontrol and the second photographing control in the display unit are thesame.

In another possible design, that the display unit is configured todisplay a first photographing control on the first interface includes:the display unit is configured to display the first photographingcontrol on the first interface in a floating manner.

In another possible design, the display unit is further configured to nolonger display the first photographing control on the first interface ifthe detection unit detects no operation on the floating firstphotographing control within a preset time after the first photographingcontrol is displayed on the first interface in the floating manner.

In another possible design, the detection unit is further configured todetect that the terminal is currently held by a left hand of the user orheld by a right hand of the user; and that the display unit isconfigured to display the first photographing control on the firstinterface in a floating manner specifically includes: the display unitis configured to display the first photographing control on a left sideof the first interface in the floating manner in response to detecting,by the detection unit, that the terminal is currently held by the lefthand of the user, or display the first photographing control on a rightside of the first interface in the floating manner in response todetecting that the terminal is currently held by the right hand of theuser.

In another possible design, before the display unit displays the firstphotographing control on the first interface, the detection unit isfurther configured to detect that the camera is in an off state.

According to a third aspect, this application provides a terminal, theterminal includes a processor, a memory, a touchscreen, a camera, andone or more sensors, and the memory, the touchscreen, the sensor, andthe camera are coupled to the processor. The memory is configured tostore computer program code, where the computer program code includes acomputer instruction. When the processor executes the computerinstruction, the one or more sensors are configured to detect a statusof holding the terminal by a user; and the touchscreen is configured todisplay a first interface, and display the first interface including afirst photographing control on the touchscreen in response to detectingthat a current status of holding the terminal by the user undergoes achange satisfying a preset condition, where the first interface is not aviewfinder interface of the terminal; and display a second interface onthe touchscreen in response to an operation of the user on the firstphotographing control, where the second interface is a viewfinderinterface of the terminal.

In a possible design, the processor is further configured to: when thetouchscreen displays the first interface, turn on the camera in responseto detecting, by the one or more sensors, that the current status ofholding the terminal by the user undergoes the change satisfying thepreset condition, to capture a preview image by using the camera.

In another possible design, the memory is configured to save, inresponse to a first operation of the user on the first photographingcontrol, a first image obtained based on the preview image.

In another possible design, that a current status of holding theterminal by the user undergoes a change satisfying a preset conditionspecifically includes: an included angle between the touchscreen and ahorizontal screen is within a preset range after the one or more sensorsdetect that the terminal is rotated and moves upward.

In another possible design, that the touchscreen is configured todisplay a second interface in response to an operation of the user onthe first photographing control includes: the touchscreen is configuredto display, in response to a second operation of the user on the firstphotographing control, a viewfinder interface in a photographing modecorresponding to the second operation, where the photographing modecorresponding to the second operation is any one of a photographing modeusing a rear-facing camera, a self-photographing mode, a panoramic mode,and a video recording mode.

In another possible design, the second interface includes a secondphotographing control; and after the touchscreen displays the secondinterface in response to the operation of the user on the firstphotographing control, the memory is configured to save, in response toa third operation of the user on the second photographing control, animage captured by the camera in response to the third operation.

In another possible design, after displaying the second interface on theterminal in response to the operation of the user on the firstphotographing control, the touchscreen is further configured to displaya third interface on the terminal in response to a fourth operation ofthe user on the second photographing control, where the fourth operationis used to instruct the terminal to switch between photographing modesof the terminal, the third interface is a viewfinder interface of theterminal in a photographing mode corresponding to the third operation,and the fourth operation is different from the third operation.

In another possible design, display positions of the first photographingcontrol and the second photographing control on the touchscreen are thesame.

In another possible design, that the touchscreen is configured todisplay the first interface including a first photographing controlincludes: the touchscreen is configured to display, in a floatingmanner, the first photographing control on the first interface displayedon the touchscreen.

In another possible design, the touchscreen is further configured to nolonger display the first photographing control on the first interface ifthe one or more sensors detect no operation on the floating firstphotographing control within a preset time after the first photographingcontrol is displayed on the first interface in the floating manner.

In another possible design, the one or more sensors are furtherconfigured to detect that the terminal is currently held by a left handof the user or held by a right hand of the user; and that thetouchscreen is configured to display the first photographing control onthe first interface in a floating manner specifically includes: thetouchscreen is configured to display the first photographing control ona left side of the first interface in the floating manner in response todetecting, by the one or more sensors, that the terminal is currentlyheld by the left hand of the user, or display the first photographingcontrol on a right side of the first interface in the floating manner inresponse to detecting that the terminal is currently held by the righthand of the user.

In another possible design, before the touchscreen displays the firstphotographing control on the first interface, the one or more sensorsare further configured to detect that the camera is in an off state.

According to a fourth aspect, this application provides a photographingmethod, which may be applied to a terminal including a camera and one ormore sensors, where the one or more sensors are configured to detect astatus of holding the terminal by a user, and the method includes:detecting a user operation in a screen-off state of the terminal; if theuser operation is an operation of lighting a screen, lighting thescreen, and displaying a first interface; if the user operation is afirst gesture, and the first gesture is that a current status of holdingthe terminal by the user undergoes a change satisfying a presetcondition, and the first gesture is different from the operation oflighting the screen, displaying a second interface, where the secondinterface is different from the first interface, a first photographingcontrol is displayed on the second interface, and the second interfaceis not a viewfinder interface of the terminal; and displaying aviewfinder interface of the terminal on the terminal in response to anoperation of the user on the first photographing control.

In this application, when the terminal is in the screen-off state, theterminal may display the first interface in response to the useroperation of lighting the screen; then if the user operation is thefirst gesture, the terminal may display the second interface includingthe first photographing control; and finally, the terminal displays theviewfinder interface of the terminal in response to the operation of theuser on the first photographing control. When the terminal automaticallydetects that the status of holding the terminal by the user undergoesthe change satisfying the preset condition, the terminal displays thesecond interface including the photographing control used to turn on thecamera, so that the user can operate the photographing control to starta “Camera” application for photographing. This can simplify useroperations for starting the “Camera” application on the terminal,improve human-machine interaction performance of the terminal, andfurther improve user experience.

According to a fifth aspect, this application provides a terminal, whichmay be applied to a terminal including a camera and one or more sensors,where the one or more sensors are configured to detect a status ofholding the terminal by a user, and the terminal includes a detectionunit and a display unit, where the detection unit is configured todetect a user operation in a screen-off state of the terminal; thedisplay unit is configured to: if the user operation detected by thedetection unit is an operation of lighting a screen, light the screen,and display a first interface; and the display unit is furtherconfigured to: if the user operation detected by the detection unit is afirst gesture, and the first gesture is that a current status of holdingthe terminal by the user undergoes a change satisfying a presetcondition, and the first gesture is different from the operation oflighting the screen, display a second interface, where the secondinterface is different from the first interface, a first photographingcontrol is displayed on the second interface, and the second interfaceis not a viewfinder interface of the terminal; and display a viewfinderinterface of the terminal in response to an operation of the user on thefirst photographing control.

According to a sixth aspect, this application provides a terminal, theterminal includes a processor, a memory, a touchscreen, a camera, andone or more sensors, and the memory, the touchscreen, and the one ormore sensors are coupled to the processor; the memory is configured tostore computer program code, where the computer program code includes acomputer instruction; the processor is configured to: when executing thecomputer instruction, detect a user operation in a screen-off state ofthe terminal; and if the user operation is an operation of lighting thetouchscreen, light the touchscreen; the touchscreen is configured todisplay a first interface when the touchscreen is lit; and thetouchscreen is further configured to: if the user operation detected bythe one or more sensors is a first gesture, and the first gesture isthat a current status of holding the terminal by a user undergoes achange satisfying a preset condition, and the first gesture is differentfrom the operation of lighting the screen, display a second interface,where the second interface is different from the first interface, afirst photographing control is displayed on the second interface, andthe second interface is not a viewfinder interface of the terminal; anddisplay a viewfinder interface of the terminal in response to anoperation of the user on the first photographing control.

It may be understood that, the terminals in the fifth aspect and thesixth aspect and possible designs thereof are all configured to performthe corresponding methods provided above. Therefore, for beneficialeffects that the terminals can achieve, refer to beneficial effects inthe corresponding methods provided above. Details are not describedagain herein.

According to a seventh aspect, this application provides a controlmethod, which may be applied to a terminal including a microphone andone or more sensors, and the sensor is configured to detect a status ofholding the terminal by a user, and the method includes: displaying amicrophone control on a screen of the terminal in a microphone-off stateof the terminal in response to detecting that a current status ofholding the terminal by the user undergoes a change satisfying a presetcondition; and turning on the microphone in response to an operation ofthe user on the microphone control.

When the microphone of the terminal is in the off state, and it isdetected that the status of holding the terminal by the user undergoesthe change satisfying the preset condition, the microphone control isdisplayed on the screen of the terminal, so that the user can turn onthe microphone by operating the microphone control, to record voicedata. This can simplify user operations for recording the voice data onthe terminal, improve human-machine interaction performance of theterminal, and further improve user experience.

In a possible design, the displaying a microphone control on a screen ofthe terminal is specifically: displaying the microphone control on thescreen of the terminal in a floating manner.

In another possible design, the method in this application may furtherinclude: displaying the microphone control in a high-frequency toucharea on a left side of the screen of the terminal in response todetecting that the terminal is held by a left hand of the user, ordisplaying the microphone control in a high-frequency touch area on aright side of the screen of the terminal in response to detecting thatthe terminal is held by a right hand of the user.

The terminal may display the microphone control in the high-frequencytouch area on the left side of the screen when the terminal is held bythe left hand of the user, or display the microphone control in thehigh-frequency touch area on the right side of the screen when theterminal is held by the right hand of the user, so that the user canoperate the microphone more conveniently and comfortably, and userexperience can be improved.

In another possible design, that a current status of holding theterminal by the user undergoes a change satisfying a preset conditionspecifically includes: an included angle between a touchscreen of theterminal and a horizontal line is within a preset range after the one ormore sensors detect that the terminal is rotated and moves upward.

In another possible design, the turning on the microphone in response toan operation of the user on the microphone control specificallyincludes: turning on the microphone in response to the operation of theuser on the microphone control, and enabling a speech recognitionfunction.

According to an eighth aspect, this application provides a terminal, theterminal includes a microphone and one or more sensors, and the terminalfurther includes a detection unit, a display unit, and a turn-on unit;the detection unit is configured to detect, by using the sensor, astatus of holding the terminal by a user; the display unit is configuredto display a microphone control in a microphone-off state of theterminal in response to detecting, by the detection unit, that a currentstatus of holding the terminal by the user undergoes a change satisfyinga preset condition; and the turn-on unit is configured to turn on themicrophone in response to an operation of the user on the microphonecontrol.

In a possible design, the display unit is specifically configured todisplay the microphone control in a floating manner.

In another possible design, the display unit is specifically configuredto display the microphone control in a high-frequency touch area on aleft side of a screen of the terminal in response to detecting, by thedetection unit, that the terminal is held by a left hand of the user, ordisplay the microphone control in a high-frequency touch area on a rightside of a screen of the terminal in response to detecting, by thedetection unit, that the terminal is held by a right hand of the user.

In another possible design, that a current status of holding theterminal by the user undergoes a change satisfying a preset conditionspecifically includes: an included angle between a touchscreen of theterminal and a horizontal line is within a preset range after thedetection unit detects, by using the one or more sensors, that theterminal is rotated and moves upward.

In another possible design, the turn-on unit is specifically configuredto turn on the microphone in response to the operation of the user onthe microphone control, and enable a speech recognition function.

According to a ninth aspect, this application provides a terminal, theterminal includes a processor, a memory, a microphone, a touchscreen,and one or more sensors, and the memory, the touchscreen, and the one ormore sensors are coupled to the processor; the memory is configured tostore computer program code, where the computer program code includes acomputer instruction; and when the processor executes the computerinstruction, the one or more sensors are configured to detect a statusof holding the terminal by a user; the touchscreen is configured todisplay a microphone control in the microphone-off state in response todetecting, by the one or more sensors, that a current status of holdingthe terminal by the user undergoes a change satisfying a presetcondition; and the processor is further configured to turn on themicrophone in response to an operation of the user on the microphonecontrol displayed by the touchscreen.

In a possible design, the touchscreen displays the microphone control ina floating manner.

In another possible design, the touchscreen is specifically configuredto display the microphone control in a high-frequency touch area on aleft side of the screen of the terminal in response to detecting, by theone or more sensors, that the terminal is held by a left hand of theuser, or display the microphone control in a high-frequency touch areaon a right side of the screen of the terminal in response to detecting,by the one or more sensors, that the terminal is held by a right hand ofthe user.

In another possible design, that a current status of holding theterminal by the user undergoes a change satisfying a preset conditionspecifically includes: an included angle between the touchscreen of theterminal and a horizontal line is within a preset range after the one ormore sensors detect that the terminal is rotated and moves upward.

In another possible design, the processor is further configured to turnon the microphone in response to the operation of the user on themicrophone control, and enable a speech recognition function.

According to a tenth aspect, this application provides a communicationmethod, which may be applied to a terminal including a left antenna anda right antenna, where the left antenna is disposed on a left part ofthe terminal, the right antenna is disposed on a right part of theterminal, and the method in this application includes: in a voicecommunication process of the terminal, detecting a current status ofholding the terminal by a user; and when the current status of holdingthe terminal by the user is a state of holding the mobile phone by aleft hand, increasing transmit/receive power of the right antenna; orwhen the current status of holding the terminal by the user is a stateof holding the mobile phone by a right hand, increasing transmit/receivepower of the left antenna.

In this application, the terminal may determine, in the voicecommunication process of the terminal, the status of holding theterminal by the user; and when the status of holding the terminal by theuser is the state of holding by the left hand, considering that the leftantenna may suffer relatively great interference, to ensure that voicecommunication quality of the terminal is not affected, thetransmit/receive power of the right antenna may be increased; or whenthe current status of holding the terminal by the user is the state ofholding by the right hand, considering that the right antenna may sufferrelatively great interference, to ensure that voice communicationquality of the terminal is not affected, the transmit/receive power ofthe left antenna may be increased.

In a possible design, when the status of holding the terminal by theuser is the state of holding by the left hand, the left antenna maysuffer relatively great interference; or when the status of holding theterminal by the user is the state of holding by the right hand, theright antenna may suffer relatively great interference. Therefore, ifone antenna of the terminal suffers relatively great interference, toreduce power consumption of the terminal, the terminal may reducetransmit/receive power of the antenna. Specifically, after the detectinga current status of holding the terminal by a user in a voicecommunication process of the terminal, the method in this applicationfurther includes: when the status of holding the terminal by the user isthe state of holding by the left hand, suppressing the transmit/receivepower of the left antenna; or when the status of holding the terminal bythe user is the state of holding by the right hand, suppressing thetransmit/receive power of the right antenna.

The terminal may increase transmit/receive power of one antenna thatsuffers less interference, and suppress transmit/receive power of theother antenna that suffers more interference. Therefore, powerconsumption of the terminal can be reduced while it is ensured thatvoice communication quality of the terminal is not affected.

In another possible design, to improve efficiency of performing voicecommunication by the user by using the terminal, the terminal mayfurther adjust volume of a left voice channel and volume of a rightvoice channel of the terminal based on the status of holding theterminal by the user. After the detecting a current status of holdingthe terminal by a user in a voice communication process of the terminal,the method in this application further includes: when the current statusof holding the terminal by the user is the state of holding the mobilephone by the left hand, turning up the volume of the left voice channelof the terminal; or when the current status of holding the terminal bythe user is the state of holding the mobile phone by the right hand,turning up the volume of the right voice channel of the terminal.

If the current status of holding the terminal by the user is the stateof holding the mobile phone by the right hand, it indicates that theright side of the terminal is closer to an ear of the user. To enablethe user to more clearly hear voice information transmitted from a peerdevice in the voice communication, the terminal may turn up the volumeof the right voice channel of the terminal.

In another possible design, when the current status of holding theterminal by the user is the state of holding the mobile phone by theleft hand, the terminal may turn down the volume of the right voicechannel of the terminal; or when the current status of holding theterminal by the user is the state of holding the mobile phone by theright hand, the terminal may turn down the volume of the left voicechannel of the terminal. Therefore, adverse impact of the voiceinformation transmitted from the peer device on other users in the voicecommunication process of the terminal can be reduced, and a possibilityof hearing content of the voice communication by the other users can befurther reduced. This helps protect privacy of the user.

According to an eleventh aspect, this application provides a terminal,the terminal includes a left antenna and a right antenna, the leftantenna is disposed on a left part of the terminal, the right antenna isdisposed on a right part of the terminal, and the terminal includes acommunications unit and a processing unit; the communications unit isconfigured to perform voice communication; and the processing unit isconfigured to: in the voice communication process of the communicationsunit, detect a current status of holding the terminal by a user; andwhen the current status of holding the terminal by the user is a stateof holding the mobile phone by a left hand, increase transmit/receivepower of the right antenna; or when the current status of holding theterminal by the user is a state of holding the mobile phone by a righthand, increase transmit/receive power of the left antenna.

In a possible design, the processing unit is further configured to: inthe voice communication process of the communications unit, afterdetecting the current status of holding the terminal by the user, whenthe current status of holding the terminal by the user is the state ofholding the mobile phone by the left hand, suppress the transmit/receivepower of the left antenna; or when the current status of holding theterminal by the user is the state of holding the mobile phone by theright hand, suppress the transmit/receive power of the right antenna.

In another possible design, the processing unit is further configuredto: after detecting the current status of holding the terminal by theuser, when the current status of holding the terminal by the user is thestate of holding the mobile phone by the left hand, turn up volume of aleft voice channel of the terminal; or when the current status ofholding the terminal by the user is the state of holding the mobilephone by the right hand, turn up volume of a right voice channel of theterminal.

According to a twelfth aspect, this application provides a terminal, theterminal includes a left antenna and a right antenna, the left antennais disposed on a left part of the terminal, the right antenna isdisposed on a right part of the terminal, and the terminal furtherincludes a communications interface, a processor, and a memory; thememory is configured to store computer program code, where the computerprogram code includes a computer instruction; and when the processorexecutes the computer instruction, the communications interface isconfigured to perform voice communication; and the processor isconfigured to: in the voice communication process of the communicationsinterface, detect a current status of holding the terminal by a user;and when the current status of holding the terminal by the user is astate of holding the mobile phone by a left hand, increasetransmit/receive power of the right antenna; or when the current statusof holding the terminal by the user is a state of holding the mobilephone by a right hand, increase transmit/receive power of the leftantenna.

In a possible design, the processor is further configured to: in thevoice communication process of the communications interface, afterdetecting the status of holding the terminal by the user, when thecurrent status of holding the terminal by the user is the state ofholding the mobile phone by the left hand, suppress the transmit/receivepower of the left antenna; or when the current status of holding theterminal by the user is the state of holding the mobile phone by theright hand, suppress the transmit/receive power of the right antenna.

In another possible design, the processor is further configured to:after detecting the current status of holding the terminal by the user,when the current status of holding the terminal by the user is the stateof holding the mobile phone by the left hand, turn up volume of a leftvoice channel of the terminal; or when the current status of holding theterminal by the user is the state of holding the mobile phone by theright hand, turn up volume of a right voice channel of the terminal.

According to a thirteenth aspect, this application provides a controldevice, the control device includes a processor and a memory, the memoryis configured to store computer program code, the computer program codeincludes a computer instruction, and when the processor executes thecomputer instruction, the processor performs the method in the firstaspect, the fourth aspect, the seventh aspect, the tenth aspect, or anypossible design thereof.

According to a fourteenth aspect, this application provides a computerstorage medium including an instruction, and when the computerinstruction is run on a terminal, the terminal is enabled to perform themethod in the first aspect, the fourth aspect, the seventh aspect, thetenth aspect, and any possible design thereof.

According to a fifteenth aspect, this application provides a computerprogram product, and when the computer program product is run on acomputer, the computer is enabled to perform the method in the firstaspect, the fourth aspect, the seventh aspect, the tenth aspect, and anypossible design thereof.

It may be understood that, the terminals in the second aspect, the thirdaspect, the fifth aspect, the sixth aspect, the eighth aspect, the ninthaspect, the eleventh aspect, the twelfth aspect, and any possible designthereof, the control device in the thirteenth aspect, the computerstorage medium in the fourteenth aspect, and the computer programproduct in the fifteenth aspect are all configured to perform thecorresponding methods provided above. Therefore, for beneficial effectsthat the terminals, the control device, the computer storage medium, andthe computer program product can achieve, refer to beneficial effects inthe corresponding methods provided above. Details are not describedagain herein.

BRIEF DESCRIPTION OF DRAWINGS

FIG. 1 is a schematic structural diagram of hardware of a terminalaccording to this application;

FIG. 2 is a flowchart 1 of a photographing method according to thisapplication;

FIG. 3A is a schematic diagram 1 of an example of a mobile phoneinterface according to this application;

FIG. 3B is another schematic diagram 1 of an example of a mobile phoneinterface according to this application;

FIG. 3C is another schematic diagram 1 of an example of a mobile phoneinterface according to this application;

FIG. 4A IS a schematic diagram 2 of an example of a mobile phoneinterface according to this application;

FIG. 4B is another schematic diagram 2 of an example of a mobile phoneinterface according to this application;

FIG. 5 is a schematic diagram 3 of an example of a mobile phoneinterface according to this application;

FIG. 6 is a flowchart 2 of a photographing method according to thisapplication;

FIG. 7 is a schematic diagram 4 of an example of a mobile phoneinterface according to this application;

FIG. 8A is a schematic diagram 5 of an example of a mobile phoneinterface according to this application;

FIG. 8B is another schematic diagram 5 of an example of a mobile phoneinterface according to this application;

FIG. 9 is a flowchart 3 of a photographing method according to thisapplication;

FIG. 10 is a schematic diagram 6 of an example of a mobile phoneinterface according to this application;

FIG. 11 is a schematic diagram 7 of an example of a mobile phoneinterface according to this application;

FIG. 12 is a flowchart 4 of a photographing method according to thisapplication;

FIG. 13 is a schematic diagram 8 of an example of a mobile phoneinterface according to this application;

FIG. 14 is a flowchart 5 of a photographing method according to thisapplication;

FIG. 15 is a schematic diagram 9 of an example of a mobile phoneinterface according to this application;

FIG. 16 A is a schematic diagram 10 of an example of a mobile phoneinterface according to this application;

FIG. 16B is another schematic diagram 10 of an example of a mobile phoneinterface according to this application;

FIG. 17 is a flowchart of a control method according to thisapplication;

FIG. 18A is a schematic diagram 11 of an example of a mobile phoneinterface according to this application;

FIG. 18B is another schematic diagram 11 of an example of a mobile phoneinterface according to this application;

FIG. 19 is a schematic diagram 12 of an example of a mobile phoneinterface according to this application;

FIG. 20 is a flowchart 1 of a communication method according to thisapplication;

FIG. 21 is a schematic diagram of a division example of a left side anda right side of a mobile phone according to this application;

FIG. 22 is a flowchart 2 of a communication method according to thisapplication;

FIG. 23 is a schematic diagram 13 of an example of a mobile phoneinterface according to this application;

FIG. 24 is a schematic structural diagram 1 of a terminal according tothis application;

FIG. 25 is a schematic structural diagram 2 of a terminal according tothis application; and

FIG. 26 is a schematic structural diagram 3 of a terminal according tothis application.

DESCRIPTION OF EMBODIMENTS

The terms “first” and “second” mentioned below are merely intended fordescription, and shall not be understood as an indication or implicationof relative importance or an implicit indication of a quantity ofindicated technical features. Therefore, a feature defined by “first” or“second” may explicitly or implicitly include one or more features. Inthe description of this application, unless otherwise stated, “aplurality of” means two or more than two.

A method provided in an embodiment of this application may be asfollows: When detecting that a status of holding a terminal by a userundergoes a change satisfying a preset condition, the terminalautomatically displays a control used to start a preset application or apreset function in the terminal; and then in response to a presetoperation of the user on the control, the terminal may start theapplication corresponding to the preset operation or perform thefunction corresponding to the preset operation; or if the terminal doesnot detect a preset operation of the user on the control within a presettime after the terminal displays the control, the terminal may notcontinue to display the control, that is, the control may disappear on adisplay screen of the terminal.

In an embodiment of this application, a photographing method and aterminal are provided, and the method may be applied to a process ofstarting a “Camera” application by the terminal for photographing.Specifically, the terminal may detect a status of holding the terminalby a user, and when the terminal displays a first interface, theterminal displays, on the first interface in response to detecting thatthe status of holding the terminal by the user undergoes a changesatisfying a preset condition, a photographing control used to turn on acamera, so that the user can operate the photographing control to startthe “Camera” application for photographing. The terminal automaticallydetects the status of holding the terminal by the user, and displays thephotographing control used to turn on the camera, so that the user canoperate the photographing control to start the “Camera” application forphotographing. This can simplify user operations for starting the“Camera” application on the terminal, improve human-machine interactionperformance of the terminal, and further improve user experience.

It should be noted that, the terminal in this application includes thecamera and a sensor, and the sensor is configured to detect the statusof holding the terminal by the user. For example, the terminal may be amobile phone (such as a mobile phone 100 shown in FIG. 1), a tabletcomputer, a personal computer (Personal Computer, PC), a personaldigital assistant (personal digital assistant, PDA), a smartwatch, anetbook, a wearable electronic device, or the like. A specific form ofthe apparatus is not specifically limited in this application.

The method provided in this embodiment of this application may beperformed by an apparatus for performing the method, for example, aphotographing apparatus. The photographing apparatus may be the mobilephone 100 shown in FIG. 1; or the photographing apparatus may be acentral processing unit (Central Processing Unit, CPU for short) in theterminal, or a control module that is in the terminal and is configuredto perform the photographing method. In this embodiment of the presentinvention, the photographing method is described by using an example inwhich the terminal performs the photographing method.

As shown in FIG. 1, the mobile phone 100 is used as an example of theterminal. The mobile phone 100 may specifically include components suchas a processor 101, a radio frequency (Radio Frequency, RF) circuit 102,a memory 103, a touchscreen 104, a Bluetooth apparatus 105, one or moresensors 106, a Wi-Fi apparatus 107, a positioning apparatus 108, anaudio circuit 109, a peripheral interface 110, and a power source 111.The components may perform communication by using one or morecommunications buses or signal cables (not shown in FIG. 1). A personskilled in the art may understand that, a hardware structure shown inFIG. 1 does not constitute a limitation on the mobile phone. A quantityof components included in the mobile phone 100 may be greater or lessthan that shown in the figure, or some components are combined, orcomponent arrangements are different.

The following describes each component of the mobile phone 100 in detailwith reference to FIG. 1.

The processor 101 is a control center of the mobile phone 100. Theprocessor 101 is connected to all parts of the mobile phone 100 by usingvarious interfaces and lines, and executes various functions and dataprocessing of the mobile phone 100 by running or executing anapplication program stored in the memory 103 and invoking data stored inthe memory 103. In some embodiments, the processor 101 may include oneor more processing units. In some embodiments of this application, theprocessor 101 may further include a fingerprint verification chip,configured to verify a captured fingerprint.

The radio frequency circuit 102 may be configured to receive and sendradio signals. Particularly, after receiving downlink data from a basestation, the radio frequency circuit 102 may send the downlink data tothe processor 101 for processing, and send uplink data to the basestation. Generally, the radio frequency circuit includes but is notlimited to an antenna, at least one amplifier, a transceiver, a coupler,a low noise amplifier, a duplexer, or the like. In addition, the radiofrequency circuit 102 may further communicate with another devicethrough wireless communication. The wireless communication may be basedon any communication standard or protocol, including but not limited tothe global system for mobile communications, general packet radioservice, code division multiple access, wideband code division multipleaccess, long term evolution, or the like.

The memory 103 is configured to store the application program and data.The processor 101 executes various functions and data processing of themobile phone 100 by running the application program stored in the memory103 and invoking data stored in the memory 103. The memory 103 mainlyincludes a program storage area and a data storage area. The programstorage area may store an operating system, an application programrequired by at least one function (such as an audio playing function oran image reviewing function). The data storage area may store data (suchas audio data or a phone book) that is created according to usage of themobile phone 100. In addition, the memory 103 may include a high-speedrandom access memory (Random Access Memory, RAM), and may furtherinclude a non-volatile memory, for example, a magnetic disk storagedevice, a flash memory, or another non-volatile solid-state storagedevice. The memory 103 may store various operating systems. The memory103 may be independent, and is connected to the processor 101 by usingthe communications bus; or the memory 103 may be integrated with theprocessor 101.

The touchscreen 104 may specifically include a touchpad 104-1 and adisplay 104-2.

The touchpad 104-1 may capture a touch event of a user of the mobilephone 100 on or near the touchpad (for example, an operation performedby the user by using any appropriate object such as a finger or a styluson the touchpad 104-1 or near the touchpad 104-1), and send capturedtouch information to another component (for example, the processor 101).The touch event near the touchpad 104-1 may be referred to as a floatingtouch. The floating touch may be that the user does not need to directlytouch the touchpad for selecting, moving, or dragging an object (forexample, an icon), and that the user only needs to be located near thedevice for ease of performing a required function. In addition, thetouchpad 104-1 may be a resistive touchpad, a capacitive touchpad, aninfrared touchpad, or a surface acoustic wave touchpad.

The display (also referred to as a display screen) 104-2 may beconfigured to display information input by the user or informationprovided for the user and various menus of the mobile phone 100. Thedisplay 104-2 may be configured in a form of a liquid crystal display,an organic light-emitting diode, or the like. The touchpad 104-1 maycover the display 104-2. After detecting the touch event on or near thetouchpad 104-1, the touchpad 104-1 transmits the touch event to theprocessor 101 to determine a type of the touch event. Then the processor101 may provide a corresponding visual output on the display 104-2 basedon the type of the touch event.

It should be noted that, although the touchpad 104-1 and the displayscreen 104-2 are used as two independent components to implement inputand output functions of the mobile phone 100 in FIG. 1, the touchpad104-1 and the display screen 104-2 may be integrated to implement theinput and output functions of the mobile phone 100 in some embodiments.It may be understood that, the touchscreen 104 may be formed by aplurality of stacked layers of materials. Only the touchpad (layer) andthe display screen (layer) are presented in this embodiment of thisapplication. Other layers are not described in this embodiment of thisapplication. In addition, the touchpad 104-1 may be configured on afront side of the mobile phone 100 in a form of a complete panel, andthe display screen 104-2 may also be configured on the front side of themobile phone 100 in a form of a complete panel. Therefore, a bezel-lessstructure can be implemented for the front side of the mobile phone.

In addition, the mobile phone 100 may further have a fingerprintrecognition function. For example, a fingerprint recognizer 112 may beconfigured on a rear side (for example, below a rear-facing camera) ofthe mobile phone 100, or a fingerprint recognizer 112 is configured on afront side (for example, below the touchscreen 104) of the mobile phone100. For another example, a fingerprint recognizer 112 may be configuredin the touchscreen 104 to implement the fingerprint recognitionfunction. To be specific, the fingerprint recognizer 112 may beintegrated with the touchscreen 104 to implement the fingerprintrecognition function of the mobile phone 100. In this case, thefingerprint recognizer 112 is configured in the touchscreen 104, and maybe a part of the touchscreen 104, or may be configured in thetouchscreen 104 in another manner. A main component of the fingerprintrecognizer 112 in this embodiment of this application is a fingerprintsensor. The fingerprint sensor may use any type of sensing technology,including but not limited to an optical, capacitive, piezoelectric, orultrasonic sensing technology, or the like.

The mobile phone 100 may further include the Bluetooth apparatus 105,configured to implement data exchange between the mobile phone 100 andanother short-range device (for example, a mobile phone or asmartwatch). The Bluetooth apparatus in this embodiment of thisapplication may be an integrated circuit, a Bluetooth chip, or the like.

The one or more sensors 106 include but are not limited to the foregoingsensor. For example, the one or more sensors 106 may further include alight sensor, a motion sensor, and another sensor. Specifically, thelight sensor may include an ambient light sensor and a proximity sensor.The ambient light sensor may adjust luminance of the touchscreen 104based on brightness of ambient light. The proximity sensor may turn offthe display when the mobile phone 100 moves to an ear. As a type ofmotion sensor, an accelerometer sensor may detect accelerationmagnitudes in all directions (generally tri-axis), and when theaccelerometer sensor is stationary, may detect a magnitude and adirection of gravity, and may be used in a posture recognitionapplication of the mobile phone (for example, switching betweenlandscape orientation and portrait orientation, a related game, ormagnetometer posture calibration), a function related to vibrationrecognition (for example, a pedometer or a stroke), or the like. Forother sensors that may be configured for the mobile phone 100, such as agyroscope, a barometer, a hygrometer, a thermometer, and an infraredsensor, details are not described herein.

The Wi-Fi apparatus 107 is configured to provide network accesscomplying with a Wi-Fi related standard for the mobile phone 100. Byusing the Wi-Fi apparatus 107, the mobile phone 100 may access a Wi-Fihotspot, and further help the user send and receive e-mails, browse webpages, access streaming media, and the like. The Wi-Fi apparatus 107provides wireless broadband Internet access for the user. In otherembodiments, the Wi-Fi apparatus 107 may also be used as a Wi-Fiwireless access point, and may provide Wi-Fi network access for anotherdevice.

The positioning apparatus 108 is configured to provide a geographiclocation for the mobile phone 100. It may be understood that, thepositioning apparatus 108 may be specifically a receiver of apositioning system such as a global positioning system (GlobalPositioning System, GPS), a BeiDou navigation satellite system, orRussian GLONASS.

After receiving the geographic location information sent by thepositioning system, the positioning apparatus 108 sends the informationto the processor 101 for processing, or sends the information to thememory 103 for storage. Alternatively, in other embodiments, thepositioning apparatus 108 may be a receiver of an assisted globalpositioning system (Assisted Global Positioning System, AGPS). The AGPS,as an assistance server, assists the positioning apparatus 108 incompleting ranging and positioning services. In this case, thepositioning assistance server communicates with the positioningapparatus 108 (that is, a GPS receiver) of a device such as the mobilephone 100 to provide positioning assistance.

Alternatively, in other embodiments, the positioning apparatus 108 mayuse a positioning technology based on a Wi-Fi hotspot. Because eachWi-Fi hotspot has a globally unique media access control (Media AccessControl, MAC) address, the device may scan and capture broadcast signalsof nearby Wi-Fi hotspots when Wi-Fi is enabled, and therefore can obtainMAC addresses broadcast by the Wi-Fi hotspots; the device sends, to alocation server by using a wireless communications network, data (forexample, the MAC addresses) that can identify the Wi-Fi hotspots; andthe location server retrieves a geographic location of each Wi-Fihotspot, calculates the geographic location of the device with referenceto strength of the Wi-Fi broadcast signals, and sends the geographiclocation to the positioning apparatus 108 of the device.

The audio circuit 109, a speaker 113, and a microphone 114 may providean audio interface between the user and the mobile phone 100. The audiocircuit 109 may convert received audio data into an electrical signaland then transmit the electrical signal to the speaker 113, and thespeaker 113 converts the electrical signal into an audio signal foroutputting. In addition, the microphone 114 converts a captured audiosignal into an electrical signal, and the audio circuit 109 converts thereceived electrical signal into audio data and then outputs the audiodata to the RF circuit 102; and then the audio data is transmitted toanother mobile phone, or the audio data is output to the memory 103 forfurther processing.

The peripheral interface 110 is configured to provide various interfacesfor external input/output devices (for example, a keyboard, a mouse, anexternal display, an external memory, and a subscriber identity modulecard). For example, the peripheral interface is connected to the mouseby using a universal serial bus (Universal Serial Bus, USB) interface,or connected, by using a metal contact in a subscriber identity modulecard slot, to a subscriber identity module (Subscriber Identity Module,SIM) card provided by a telecommunications operator. The peripheralinterface 110 may be configured to couple the external input/outputperipheral device to the processor 101 and the memory 103.

In this embodiment of the present invention, the mobile phone 100 maycommunicate with another device in a device group by using theperipheral interface 110, for example, may receive, by using theperipheral interface 110, displayed data sent by another device anddisplay the data. This is not limited in this embodiment of the presentinvention.

The mobile phone 100 may further include the power source apparatus 111(such as a battery and a power management chip) supplying power to eachcomponent. The battery may be logically connected to the processor 101by using the power management chip, so that functions such as charge anddischarge management and power consumption management are implemented byusing the power source apparatus 111.

Although not shown in FIG. 1, the mobile phone 100 may further include acamera (a front-facing camera and/or a rear-facing camera), a flash, amicro projection apparatus, a near field communications (Near FieldCommunications, NFC) apparatus, and the like. Details are not describedherein.

All methods in the following embodiments may be implemented in themobile phone 100 having the foregoing hardware structure.

An embodiment of this application provides a photographing method. Thephotographing method may be applied to a terminal, the terminal includesa camera and one or more sensors, and the one or more sensors areconfigured to detect a status of holding the terminal by a user. Asshown in FIG. 2, the photographing method includes S201 to S203.

S201. A terminal detects a status of holding the terminal by a user.

The terminal may detect, by using a sensor in the terminal, the statusof holding the terminal by the user.

S202. The terminal displays a first interface, and displays a firstphotographing control on the first interface in response to detectingthat a current status of holding the terminal by the user undergoes achange satisfying a preset condition, where the first interface is not aviewfinder interface of the terminal.

The first interface in this embodiment of this application may be aninterface displayed when the terminal is in a screen-on state. Thescreen-on state may include a state of displaying a locked-screeninterface by the terminal, a state of displaying a home screen (that is,an interface including a plurality of application icons) by theterminal, a state of displaying a display interface of any applicationby the terminal, or the like. This is not limited in this application.

For example, the terminal is the mobile phone 100 shown in FIG. 1. Thefirst interface may be a locked-screen interface 301 shown in FIG. 3A;or the first interface may be a home screen 302 shown in FIG. 3B; or thefirst interface may be an interface 303 of a “Browser” application shownin FIG. 3C. Certainly, the first interface may also be a displayinterface of the mobile phone 100 for displaying another application(such as a “WeChat” application or an “Alipay” application). This is notlimited in this embodiment of this application.

The one or more sensors in this embodiment of this application maydetermine, by detecting that the terminal is rotated, or that theterminal moves forward relatively to the user, or that the terminalmoves upward relatively to a horizontal line, whether the status ofholding the terminal by the user undergoes the change satisfying thepreset condition. Specifically, the terminal may detect a motionparameter of the terminal; then determine, based on the motionparameter, whether the terminal is rotated, or whether the terminalmoves forward relatively to the user, or whether the terminal movesupward relatively to the horizontal line; and finally determine, basedon a determining result, whether the status of holding the terminal bythe user undergoes the change satisfying the preset condition. Forexample, as shown in Table 1, this application provides a table ofchanges of statuses of holding the terminal.

TABLE 1 Table of changes of statuses of holding the terminal ConditionRotated Moving forward Moving upward Icon status Case of 1 Yes Yes YesNormally displayed condition 2 Yes Yes Yes, but an A displayed icon issatisfaction amplitude is small, and insufficient transparency is high 3Yes Yes, but an Yes A displayed icon is amplitude is small, andinsufficient transparency is high 4 Yes No, or within an Yes Notdisplayed anti-jitter range 5 Yes Yes No, or within an Not displayedanti-jitter range 6 Yes No, or within an No, or within an Not displayedanti-jitter range anti-jitter range 7 No Yes Yes Not displayed

Referring to Table 1, as shown in the case 1, when the motion parameterdetected by the sensor in the terminal indicates that the terminal is“rotated”, “moving forward”, and “moving upward”, the firstphotographing control may be normally displayed.

As shown in the case 2, when the motion parameter detected by the sensorin the terminal indicates that the terminal is “rotated”, “movingforward”, and “moving upward, but an upward amplitude is insufficient(that is, the upward motion amplitude is less than a first presetamplitude)”, the first photographing control may be normally displayedbut is relatively small, and transparency of the first photographingcontrol is relatively high (that is, transparency of the first controldisplayed in the case 2 is higher than that of the first controldisplayed in the case 1).

As shown in the case 3, when the motion parameter detected by the sensorin the terminal indicates that the terminal is “rotated”, “movingforward (that is, a forward motion amplitude is less than a secondpreset amplitude)”, and “moving upward”, the first photographing controlmay be normally displayed but is relatively small, and transparency ofthe first photographing control is relatively high.

As shown in the case 4, when the sensor in the terminal detects that theterminal is “rotated”, “not moving forward, but a forward motionamplitude is within an anti jitter range”, and “moving upward”, theterminal does not display the first photographing control on the firstinterface.

Likewise, the terminal may determine, based on the cases 5 and 6 shownin Table 1, whether the terminal displays the first photographingcontrol on the first interface, and when the terminal needs to displaythe first photographing control, determine a size and transparency ofthe to-be-displayed first photographing control.

It should be noted that, in this embodiment of this application, amethod for determining, by the terminal, whether the status of holdingthe terminal by the user undergoes the change satisfying the presetcondition and a determining condition include but are not limited todescriptions in the foregoing embodiment. Other determining methods anddetermining conditions are not described herein in this embodiment ofthis application.

In addition, the foregoing determining may occur when neither afront-facing camera nor a rear-facing camera is turned on. In addition,the foregoing determining may occur when it is determined that a currentscenario is a non-game scenario, that is, it is determined that the useris currently not playing a game, to exclude possible incorrectdetermining.

Generally, for example, the terminal is a mobile phone 100 shown in FIG.4A and FIG. 4B. When the user uses the mobile phone 100 forphotographing, as shown in (a-1) in FIG. 4A, the user may pick up themobile phone 100; then as shown in (a-1) in FIG. 4A to (b) in FIG. 4A,the user may gradually raise an arm until the mobile phone isapproximately vertical to the ground as shown in (c-1) in FIG. 4A. Inthis case, the user may start to take a photo.

For example, in this embodiment, “a current status of holding theterminal by the user undergoes a change satisfying a preset condition”may specifically include: an included angle between a display screen ofthe terminal and a horizontal screen is within a preset range after thesensor detects that the terminal is rotated and moves upward.

For example, when the mobile phone 100 displays the first interfaceshown in FIG. 3C, and the status of holding the mobile phone 100 by theuser undergoes a change shown in (a-1) in FIG. 4A to (b) in FIG. 4A to(c-1) in FIG. 4A (that is, undergoes the change satisfying the presetcondition), the mobile phone 100 may display the first photographingcontrol on the first interface.

It should be noted that, the change satisfying the preset condition inthis embodiment of this application includes but is not limited to thechange shown in (a-1) in FIG. 4A to (b) in FIG. 4A to (c-1) in FIG. 4A.Because different users have different photographing habits, theterminal may collect statistics about status change parameters capturedby the sensor in photographing processes of most or all users using theterminal, and determine changes of the status change parameters aschanges satisfying the preset condition. Therefore, the terminaldisplays the first interface, and when a change of the status changeparameters captured by the sensor in the terminal is a change satisfyingthe preset condition, the terminal may determine, in response, that apossibility that the user wants to take a photo by using the terminal isrelatively high, and may display the first photographing control on thefirst interface.

For example, the first interface is the interface 303 of the “Browser”application displayed by the mobile phone 100, as shown in FIG. 3C. Whenthe user holds the mobile phone 100 in a gesture shown in (a-1) in FIG.4A, the mobile phone 100 displays the first interface 303 shown in (a-2)in FIG. 4B. As shown in (a-1) in FIG. 4A to (b) in FIG. 4A to (c-1) inFIG. 4A, the gesture of holding the mobile phone 100 by the userchanges, and in a change process of the gesture of holding the mobilephone 100 by the user, the mobile phone 100 detects that the currentstatus of holding the mobile phone 100 by the user undergoes the changesatisfying the preset condition. In this case, as shown in (c-2) in FIG.4B, the mobile phone 100 may display a first photographing control 402on a first interface 401, and the first photographing control 402 isused to turn on a camera of the mobile phone 100.

It should be emphasized that the first interface in this embodiment ofthis application is not a viewfinder interface of the terminal. Forexample, the first interface may be the first interface 401 shown in(c-2) in FIG. 4B, (a) in FIG. 5, or (a) in FIG. 7, or a first interface801 shown in FIG. 8A, or a first interface 803 shown in FIG. 8B.

Optionally, the first photographing control in this embodiment of thisapplication may be displayed on the first interface in a floatingmanner. The terminal may display, on the first interface in response toa moving operation of the user on the first photographing control,dynamic images of the first photographing control that dynamically movesalong a moving track of the moving operation. For example, a position ofthe first photographing control 402 on the first interface 401 shown in(c-2) in FIG. 4B is different from a position of the first photographingcontrol 402 on the first interface 401 shown in (a) in FIG. 5.

S203. The terminal displays a second interface on the terminal inresponse to an operation of the user on the first photographing control,where the second interface is a viewfinder interface of the terminal.

In this embodiment of this application, the operation of the user on thefirst photographing control may be any one of operations of the user onthe first photographing control, such as a tap operation, a double-tapoperation, and a touch and hold operation. This is not limited in thisembodiment of this application.

For example, as shown in (a) in FIG. 5, the operation of the user on thefirst photographing control is a tap operation. After the user taps thefirst photographing control 402 shown in (a) in FIG. 5, the mobile phone100 may display, in response to the tap operation of the user on thefirst photographing control 402, a second interface 501 shown in (b) inFIG. 5. The second interface 501 shown in (b) in FIG. 5 includes aviewfinder frame 502, a camera switch key 504, a photographing key 503,and a gallery key 505.

The viewfinder frame 502 is used to display a preview image captured bythe rear-facing camera or the front-facing camera of the terminal; thecamera switch key 504 is used to trigger the terminal to switch betweenthe front-facing camera and the rear-facing camera to capture an image;the photographing key 503 is used to control the terminal to save thepreview image captured by the rear-facing camera or the front-facingcamera and displayed in the viewfinder frame 502; and the gallery key505 is used to view an image stored in the terminal. When a defaultcamera of the terminal is the rear-facing camera, the viewfinder frame502 may display the preview image captured by the rear-facing camerashown in (b) in FIG. 5.

Optionally, in S203, when the operation of the user on the firstphotographing control may be a different user operation such as a tapoperation, a double-tap operation, or a touch and hold operation, thesecond interface may also be a photographing interface in a differentphotographing mode of the terminal. To be specific, the second interfaceis a photographing interface of the terminal in a photographing modecorresponding to the foregoing operation. Photographing modes of theterminal may include at least a photographing mode using the rear-facingcamera, a self-photographing mode, a panoramic mode, and a video mode.Certainly, the photographing modes in this embodiment of thisapplication include but are not limited to the photographing mode usingthe rear-facing camera, the self-photographing mode, the panoramic mode,and the video mode. Other photographing modes are not described hereinin this embodiment of this application.

Specifically, as shown in FIG. 6, S203 shown in FIG. 2 may be replacedwith S601.

S601. The terminal displays, in response to a second operation of theuser on the first photographing control, a viewfinder interface in aphotographing mode corresponding to the second operation.

The second operation in S601 is the operation of the user on the firstphotographing control in S203. The second operation may be a differentuser operation such as a tap operation, a double-tap operation, or atouch and hold operation. The photographing mode corresponding to thesecond operation is any one of the photographing mode using therear-facing camera, the self-photographing mode, the panoramic mode, andthe video recording mode.

For example, when the second operation is a tap operation, the secondinterface may be a photographing interface of the terminal in thephotographing mode using the rear-facing camera. The photographing modeusing the rear-facing camera is a mode of using the rear-facing cameraby the terminal to capture an image. For example, after the user tapsthe first photographing control 402 shown in (a) in FIG. 5, the mobilephone 100 may display, in response to the tap operation of the user onthe first photographing control 402, the second interface 501 shown in(b) in FIG. 5. The second interface 501 shown in (b) in FIG. 5 is thephotographing interface of the terminal in the photographing mode usingthe rear-facing camera.

When the second operation is a touching and holding operation, thesecond interface may be a photographing interface of the terminal in theself-photographing mode. The self-photographing mode in this applicationis a mode of using the front-facing camera by the terminal to capture animage. For example, after the user touches and holds the firstphotographing control 402 shown in (a) in FIG. 7, the mobile phone 100may display, in response to the touch and hold operation of the user onthe first photographing control 402, a second interface 701 shown in (b)in FIG. 7. The second interface 701 shown in (b) in FIG. 7 is thephotographing interface of the terminal in the self-photographing mode.A viewfinder frame shown in (b) in FIG. 7 displays a profile picture ofthe user. When the second operation is a double-tap operation, thesecond interface may be a photographing interface of the terminal in thepanoramic mode, which is not shown in the figure.

In the photographing method provided in this embodiment of thisapplication, when the terminal is in the screen-on state, and detectsthat the status of holding the terminal by the user undergoes the changesatisfying the preset condition, the terminal displays, on the firstinterface, the photographing control used to turn on the camera, so thatthe user can operate the photographing control to start a “Camera”application for photographing. When the terminal is in the screen-onstate, and automatically detects that the status of holding the terminalby the user undergoes the change satisfying the preset condition, theterminal displays the photographing control used to turn on the camera,so that the user can operate the photographing control to start the“Camera” application for photographing. This can simplify useroperations for starting the “Camera” application on the terminal,improve human-machine interaction performance of the terminal, andfurther improve user experience.

Further, to prevent the terminal from displaying the first photographingcontrol on the first interface for a long time due to an unintentionaloperation of the user, the terminal may start timing from displaying thefirst photographing control. If the terminal does not receive a firstoperation of the user on the first photographing control within a presettime, the terminal may display the first photographing control thatgradually scales down, until the first photographing control is notdisplayed, that is, until the first photographing control disappears.For example, as shown in FIG. 8A, the mobile phone 100 displays a firstphotographing control 802 on a home screen 801 including a plurality ofapplication icons. Because no operation of the user on the firstphotographing control is received within a preset time starting fromdisplaying the first photographing control 802 by the mobile phone 100on the home screen 801 (that is, the first interface), the mobile phone100 may display a first interface 803 including a first photographingcontrol 804, as shown in FIG. 8B. In comparison with the firstphotographing control 802 shown in FIG. 8A, the first photographingcontrol 804 shown in FIG. 8B is smaller.

In this application, after the terminal displays the first photographingcontrol on the first interface, if the terminal does not receive thefirst operation of the user on the first photographing control withinthe preset time, it indicates that an action of holding the terminal bythe user may be an unintentional operation of the user. To prevent theterminal from displaying the first photographing control on the firstinterface due to an unintentional operation of the user, the terminalmay display the first photographing control that gradually scales down,until the first photographing control is not displayed.

It may be understood that, some time is needed from detecting, by theterminal in the screen-on state, that the current status of holding theterminal by the user undergoes the change satisfying the presetcondition, to displaying, by the terminal, the first interface includingthe first photographing control, and then displaying the viewfinderinterface in response to the operation of the user on the firstphotographing control. However, in some scenarios, the user may want torecord some fleeting images, but when the terminal interacts with theuser to perform the foregoing operation, the images that the user wantsto shoot possibly no longer exist, and user experience is affected.

For this case, in this embodiment of this application, when the terminalmay be in the screen-on state (that is, the terminal displays the firstinterface), the terminal may turn on the camera in the terminal inresponse to detecting that the current status of holding the terminal bythe user undergoes the change satisfying the preset condition, tocapture a preview image by using the camera. Specifically, as shown inFIG. 9, after S201 shown in FIG. 2, the method in this embodiment ofthis application may further include S901.

S901. When the terminal displays the first interface, the terminal turnson the camera in response to detecting that the current status ofholding the terminal by the user undergoes the change satisfying thepreset condition, to capture a preview image by using the camera.

In this embodiment of this application, when the terminal displays thefirst interface, the terminal may directly turn on the camera inresponse to detecting that the current status of holding the terminal bythe user undergoes the change satisfying the preset condition, and startto capture the preview image by using the camera. In addition, inresponse to detecting that the current status of holding the terminal bythe user undergoes the change satisfying the preset condition, theterminal may display the first interface including the firstphotographing control. To be specific, when displaying the firstinterface, the terminal may turn on the camera to capture the previewimage, instead of starting to capture the preview image in response tothe operation of the user on the first photographing control on thefirst interface only after the first interface is displayed. Therefore,the terminal can capture images in a time period in which the terminaldisplays the first interface, receives the operation of the user on thefirst photographing control, and displays the second interface.

It should be emphasized that, when the terminal displays the firstinterface, even if the terminal turns on the camera to capture thepreview image, a viewfinder frame (the viewfinder frame 502 shown in (b)in FIG. 5) of the camera is not displayed on the first interface. Inother words, even if the terminal has turned on the camera forviewfinder setting and photographing, because the terminal does notdisplay the viewfinder frame, the user cannot see, on the display screenof the terminal, the image captured or taken by the terminal by usingthe camera.

Because the terminal has turned on the camera when displaying the firstinterface, and has captured the preview image by using the camera, theterminal may save, in response to the operation of the user on the firstphotographing control on the first interface, the image captured by thecamera, and display the second interface. In addition, the terminal mayenable an image recognition function when turning on the camera.Therefore, when the first interface is displayed, actually the terminalhas performed image recognition/analysis on the image captured by thecamera. Therefore, an image recognition result can be obtainedimmediately after the user performs the first operation. This helpsincrease an image recognition speed, and is particularly helpful forsome motion scenarios or snap scenarios. Specifically, as shown in FIG.9, S203 shown in FIG. 2 may be replaced with S902.

S902. The terminal saves, in the terminal in response to the firstoperation of the user on the first photographing control, a first imageobtained based on the preview image, and displays the second interfaceon the terminal.

The first operation in this embodiment of this application may bedifferent from the second operation. For example, when the secondoperation is a tap operation, a touch and hold operation, or adouble-tap operation, the first operation may be a slide-up operation ora slide-down operation of the user on the first photographing control.

For example, the first image may be at least one of preview imagescaptured by the camera or a video image including a plurality of images.The terminal may analyze the preview images captured by the camera, toextract the first image from the preview images captured by the cameraand save the first image.

When the first operation is a different operation, the first image maybe different image content. For example, when the first operation is aslide-up operation of the user on the first photographing control, thefirst image saved by the terminal may be an image whose definition isthe highest in the preview images captured by the camera; or when thefirst operation is a slide-down operation of the user on the firstphotographing control, the first image saved by the terminal may be avideo image including a plurality of preview images captured by thecamera.

Certainly, the first operation and the second operation may also be thesame. A photographing mode corresponding to the first operation is anyone of the photographing mode using the rear-facing camera, theself-photographing mode, the panoramic mode, and the video recordingmode. When the photographing mode corresponding to the first operationis any one of the photographing mode using the rear-facing camera, theself-photographing mode, and the panoramic mode, the first imageincludes one or more images in the preview images; or when thephotographing mode corresponding to the first operation is the videorecording mode, the first image is a video image captured by the cameraand including a plurality of preview images.

In this application, when displaying the first interface, the terminalmay turn on the camera to capture the preview image, instead of startingto capture the preview image in response to the operation of the user onthe first photographing control on the first interface only after thefirst interface is displayed. Therefore, the terminal can capture imagesin the time period in which the terminal displays the first interface,receives the operation of the user on the first photographing control,and displays the second interface.

Optionally, to facilitate user operations, the terminal may furtheridentify whether the terminal is currently held by a left hand of theuser or held by a right hand of the user, and then display the firstphotographing control in an area that facilitates the user operations.Specifically, S202 may include S202 a.

S202 a. When the terminal displays the first interface, in response todetecting that the current status of holding the terminal by the userundergoes the change satisfying the preset condition, the terminaldisplays the first photographing control in a high-frequency touch areaon a left side of the first interface if the terminal is held by theleft hand of the user, or displays the first photographing control in ahigh-frequency touch area on a right side of the first interface if theterminal is held by the right hand of the user.

The high-frequency touch area in this application is a touch area inwhich a frequency or quantity of user operations is higher than a presetthreshold on the interface of the terminal. The terminal may determine,by using sensors, whether the terminal is held by the left hand of theuser or held by the right hand of the user. For example, the sensors maybe light sensors disposed on a left side edge and a right side edge ofthe terminal. When the terminal is held by the left hand of the user,intensity of light captured by the sensor on the right side edge isweaker than intensity of light captured by the sensor on the left sideedge, and the terminal may determine that the terminal is held by theleft hand of the user.

For example, as shown in FIG. 10, it is assumed that the mobile phone100 is held by the left hand of the user. When the mobile phone 100displays the first interface, in response to detecting that the currentstatus of holding the mobile phone 100 by the user undergoes the changesatisfying the preset condition, the mobile phone 100 may display afirst photographing control 1001 in the high-frequency touch area on theleft side of the first interface.

In this embodiment of this application, the terminal may display thefirst photographing control in the high-frequency touch area on the leftside of the first interface when the left hand of the user holds theterminal, or display the first photographing control in thehigh-frequency touch area on the right side of the first interface whenthe right hand of the user holds the terminal, so that the user canoperate the first photographing control more conveniently andcomfortably, and user experience can be improved.

Further, the second interface may include a second photographingcontrol. For example, the second interface shown in FIG. 11 may includea second photographing control 1101. The second photographing controlmay be used to control the terminal to perform photographing, andfunctions as a photographing shutter, that is, the photographing key 503shown in FIG. 11.

It may be understood that, when a touchscreen of the terminal isrelatively large, the user cannot conveniently tap the photographingshutter for photographing by using a single hand. In this case, theterminal may display the second photographing control on the secondinterface, and the user can control, by operating the secondphotographing control, the terminal to save an image captured by thecamera.

Specifically, after S203, the method in this application may furtherinclude S1201. For example, as shown in FIG. 12, after S902 (that is,S203) shown in FIG. 9, the method in this application may furtherinclude S1201.

S1201. The terminal saves, in the terminal in response to a thirdoperation of the user on the second photographing control, an imagecaptured by the camera in response to the third operation.

The third operation of the user on the second photographing control maybe a tap operation of the user on a second photographing control 1302 ona second interface 1301 shown in (a) in FIG. 13, and is equivalent to atap operation of the user on the photographing key 503 shown in (a) inFIG. 13.

For example, after the user taps the second photographing control 1302shown in (a) in FIG. 13, the mobile phone 100 may save, in response tothe third operation of the user on the second photographing control1302, an image captured by the camera in response to the thirdoperation, and display a display interface 1304 shown in (b) in FIG. 13.After the terminal responds to the third operation, a photo displayed onan icon corresponding to the gallery key 505 changes from a “girl” 1303shown in (a) in FIG. 13 to a photo 1305 shown in (b) in FIG. 13, wherethe photo 1305 is an image in the viewfinder frame shown in (a) in FIG.13.

Optionally, to facilitate user operations, when the left hand of theuser holds the terminal, the terminal may display the secondphotographing control in a high-frequency touch area on a left side ofthe second interface, or when the right hand of the user holds theterminal, the terminal may display the second photographing control in ahigh-frequency touch area on a right side of the second interface, sothat the user can operate the second photographing control moreconveniently and comfortably, and user experience can be improved. Asshown in (a) in FIG. 13, because the user holds the mobile phone 100 byusing the right hand, the mobile phone 100 may display the secondphotographing control 1302 in the high-frequency touch area on the rightside of the second interface to facilitate user operations.

In this application, the terminal may display, on the second interface,the second photographing control used to control the terminal to performphotographing, and the second photographing control may be displayed onone side on which the user holds the terminal, so that the user canoperate the second photographing control more conveniently andcomfortably. This can avoid a problem that a single hand of the usercannot conveniently tap the photographing shutter of the terminal forphotographing when the touchscreen of the terminal is relatively large,and can improve user experience.

Further, different operations of the user on the second photographingcontrol may be used to instruct the terminal to perform differentoperations. For example, the terminal may save, in response to the thirdoperation of the user on the second photographing control, the imagecaptured by the camera in response to the third operation, and switchbetween photographing modes of the terminal in response to a fourthoperation of the user on the second photographing control. The thirdoperation and the fourth operation are different. For example, the thirdoperation may be a tap operation of the user on the second photographingcontrol, and the fourth operation may be a double-tap operation or atouch and hold operation of the user on the second photographingcontrol.

Specifically, after S203, the method in this application may furtherinclude S1401. For example, as shown in FIG. 14, after S902 (that is,S203) shown in FIG. 9, the method in this application may furtherinclude S1401.

S1401. The terminal displays a third interface on the terminal inresponse to the fourth operation of the user on the second photographingcontrol, where the fourth operation is used to instruct the terminal toswitch between photographing modes of the terminal, the third interfaceis a viewfinder interface of the terminal in a photographing modecorresponding to the third operation, and the fourth operation isdifferent from the third operation.

For example, it is assumed that the third operation is a tap operationof the user on the second photographing control, and that the fourthoperation is a double-tap operation or a touch and hold operation of theuser on the second photographing control.

In a possible implementation, when the fourth operation in thisapplication is a different user operation such as a double-tap operationor a touch and hold operation, the third interface may also be aphotographing interface of the terminal in a different photographingmode. To be specific, the third interface is a photographing interfaceof the terminal in a photographing mode corresponding to the fourthoperation. For example, when the fourth operation is a double-tapoperation, the third interface is a photographing interface in thepanoramic mode; or when the fourth operation is a touch and holdoperation, the third interface is a photographing interface in theself-photographing mode.

In another possible implementation, the terminal may switch between thephotographing modes of the terminal sequentially in response to thefourth operation of the user on the second photographing control. Forexample, the terminal may switch between the photographing modes of theterminal sequentially in a sequence of the photographing mode, thepanoramic mode, the self-photographing mode, and the video recordingmode in response to the fourth operation of the user on the secondphotographing control. For example, if the terminal is in thephotographing mode currently, the terminal may switch the terminal tothe panoramic mode in response to the fourth operation of the user onthe second photographing control; if the terminal is in the panoramicmode currently, the terminal may switch the terminal to theself-photographing mode in response to the fourth operation of the useron the second photographing control; or if the terminal is in theself-photographing mode currently, the terminal may switch the terminalto the video recording mode in response to the fourth operation of theuser on the second photographing control.

For example, after the user double-taps a second photographing control1501 shown in (a) in FIG. 15, the mobile phone 100 may display, inresponse to the double-tap operation (that is, the fourth operation) ofthe user on the second photographing control 1501, a second interface1502 shown in (b) in FIG. 15. The second interface 1502 shown in (b) inFIG. 15 is a photographing interface in the panoramic mode.

In this application, the terminal may switch between the photographingmodes of the terminal in response to the fourth operation of the user onthe second photographing control. This improves efficiency of switchingbetween the photographing modes of the terminal by the user, andimproves user experience.

Optionally, in this application, as the gesture of holding the terminalby the user changes, the first photographing control may move on thefirst interface; and as the gesture of holding the terminal by the userchanges, the second photographing control may also move on the secondinterface.

For example, as the gesture of holding the terminal by the user changes,the first photographing control may move on the first interface. Asshown in (a-1) in FIG. 16A to (b-1) in FIG. 16A to (c-1) in FIG. 16A, asthe user holds and moves the mobile phone 100 upward, as shown in (a-2)in FIG. 16B to (b-2) in FIG. 16B to (c-2) in FIG. 16B, a position of afirst photographing control 1601 on the first interface also graduallymoves toward a lower bezel of the mobile phone 100 to facilitate useroperations.

Optionally, an embodiment of this application further provides a methodfor photographing in a screen-off state. The method specificallyincludes the following: A terminal is compatible with an existingoperation of lighting a screen, for example, screen lighting implementedby using a physical key or a screen-off gesture such as double-tappingthe screen or wake screen on wrist raise. When the terminal detects thata user operation satisfies a preset condition when a camera is in an offstate, the terminal displays a camera control on the screen, where thecamera control may be displayed on the lit screen, or when an AMOLED orthe like may be used to light a part of the screen, the terminal maydisplay only one control of the camera on a screen-off interface, or maydisplay a part, for example, display the camera and other controls suchas time or a status bar. In addition, the camera control may bedisplayed on the current interface in a floating manner. A user mayimplement operations on the camera control very conveniently bydragging. In addition, a display position of the camera control maychange with a current holding status of the user. For example, if theterminal detects that the current status is a right-hand holding state,the terminal displays the camera control in a high-frequency touch areaon a right side of the screen of the terminal; or if the terminaldetects that the current status is a left-hand holding state, theterminal displays the camera control in a high-frequency touch area on aleft side of the screen of the terminal. Detecting the left-hand orright-hand holding state pertains to the prior art, and is not describedherein. In response to detecting the operation of the user on the cameracontrol, the terminal displays a viewfinder interface. Specifically, fora specific implementation of the embodiment of the method forphotographing in the screen-off state, refer to the method forphotographing in the screen-on state. Details are not described again.

This application further provides a control method, the control methodmay be applied to a terminal including a microphone and a sensor, andthe sensor is configured to detect a status of holding the terminal by auser. As shown in FIG. 17, the control method includes S1701 to S1703.

S1701. A terminal detects a current status of holding the terminal by auser.

For detailed descriptions about S1701, refer to the detaileddescriptions about S201 in the foregoing embodiment of this application.Details are not described again herein in this embodiment of thisapplication.

S1702. The terminal displays a microphone control on a screen of theterminal in a microphone-off state of the terminal in response todetecting that a current status of holding the terminal by the userundergoes a change satisfying a preset condition.

It is assumed that when a mobile phone 100 displays a home screen 1801including a plurality of application icons shown in (a-2) in FIG. 18B,or when a mobile phone 100 displays a locked-screen interface, or when amobile phone 100 displays a display interface of any application, themicrophone of the terminal is not turned on.

The microphone-off state of the terminal in this embodiment may also bethat the terminal is in a screen-off state. To be specific, when theterminal is in the screen-off state, the terminal may display themicrophone control on the terminal in response to detecting that thecurrent status of holding the terminal by the user undergoes the changesatisfying the preset condition.

It should be noted that, in this embodiment of this application, whenthe terminal is in the microphone-off state, an interface displayed bythe terminal is referred to as a first interface. For the firstinterface, refer to the detailed descriptions about the first interfacein S202. Details are not described again herein in this embodiment ofthis application. For example, as shown in (b-2) in FIG. 18B, the firstinterface may be a home screen 1802 including a plurality of applicationicons. The first interface shown in (b-2) in FIG. 18B includes amicrophone control 1803. As shown in (b-2) in FIG. 19, the firstinterface may be a locked-screen interface 1901. The first interfaceshown in (b-2) in FIG. 19 includes a microphone control 1902.

Generally, for example, the terminal is a mobile phone 100 shown in FIG.18. When the user uses the mobile phone 100 for voice input, as shown in(a-1) in FIG. 18A, the user may pick up the mobile phone 100; and thenas shown in (a-1) in FIG. 18A to (b-1) in FIG. 18A, the user maygradually raise an arm until a lower end of the mobile phone 100 shownin (b-1) in FIG. 18A is close to a face of the user. In this case, theuser may start to record voice data. For example, in this embodiment, “acurrent status of holding the terminal by the user undergoes a changesatisfying a preset condition” may specifically include: a downtilt of atop of the mobile phone reaches a degree or an included angle between ahorizontal direction of the mobile phone and a horizontal line reaches apreset angle after the sensor detects that the terminal is rotated andmoves upward (detecting that the microphone of the terminal is close tothe face (specifically a lip)).

For example, when the mobile phone 100 displays the first interface (aninterface displayed by the mobile phone 100 when the mobile phone 100 isin the microphone-off state) shown in (a-2) in FIG. 18B, and the statusof holding the mobile phone 100 by the user undergoes a change (that is,the change satisfying the preset condition) shown in (a-1) in FIG. 18Ato (b-1) in FIG. 18A, the mobile phone 100 may display the firstinterface 1802 including the microphone control 1803. When the mobilephone 100 is in the screen-off state shown in (a-2) in FIG. 19, and thestatus of holding the mobile phone 100 by the user undergoes a change(that is, the change satisfying the preset condition) shown in (a-1) inFIG. 19 to (b-1) in FIG. 19, the mobile phone 100 may display the firstinterface 1901 including the microphone control 1902.

It should be noted that, the change satisfying the preset condition inthis embodiment of this application includes but is not limited to thechange shown in (a-1) in FIG. 18A to (b-1) in FIG. 18A. Becausedifferent users have different habits of recording voice data, theterminal may collect statistics about status change parameters capturedby the sensor in voice data recording processes of most or all usersusing the terminal, and determine changes of the status changeparameters as changes satisfying the preset condition. Therefore, when achange of parameters matching the status change parameters captured bythe sensor in the terminal is a change satisfying the preset condition,the terminal may determine that a possibility of using the terminal bythe user to record voice data is relatively high, and may automaticallydisplay the first interface including the microphone control. Inaddition, a system or the user may set that the foregoing action shouldbe repeated for several times and then entering a speech recognitionstate is triggered. It should be noted that, the microphone control inthis application may be displayed in a fixed position on the firstinterface; or the microphone control may be displayed on the firstinterface in a floating manner, and the terminal may display, on thefirst interface in response to a moving operation of the user on themicrophone control, dynamic images of the microphone control thatdynamically moves along a moving track of the moving operation.

Optionally, to facilitate user operations, the terminal may furtheridentify whether the terminal is currently held by a left hand of theuser or held by a right hand of the user, and then automatically displaythe microphone control in an area that facilitates the user operations.Specifically, S1702 may include S1702 a.

S1702 a. The terminal displays the microphone control on a left side ofthe first interface in the microphone-off state of the terminal inresponse to detecting that the current status of holding the terminal bythe user undergoes the change satisfying the preset condition, ordisplays the microphone control on a right side of the first interfaceif the terminal is held by a right hand of the user.

Optionally, if the terminal is held by the left hand of the user, theterminal may display the microphone control in a high-frequency toucharea on the left side of the first interface; or if the terminal is heldby the right hand of the user, the terminal may display the microphonecontrol in a high-frequency touch area on the right side of the firstinterface. The high-frequency touch area is a touch area in which afrequency or quantity of user operations is higher than a presetthreshold on the interface of the terminal.

For example, as shown in FIG. 19, when the right hand of the user holdsthe mobile phone 100, the mobile phone 100 may display the microphonecontrol 1902 in a high-frequency touch area on a right side of the firstinterface 1901 to facilitate user operations.

S1703. The terminal turns on the microphone in response to an operationof the user on the microphone control.

Specifically, S1703 may include: the terminal turns on the microphone inresponse to the operation of the user on the microphone control, andenables a speech recognition function.

In addition, the system or the user may set a gesture amplitude, or afeedback such as a haptic feedback, a visual feedback, or an auditoryfeedback to trigger entering the speech recognition state. To bespecific, a prompt such as a visual prompt, an auditory prompt, or ahaptic prompt is provided for the user when the microphone is turned on.

In this embodiment of this application, the terminal may display themicrophone control in the high-frequency touch area on the left side ofthe first interface when the terminal is held by the left hand of theuser, or display the microphone control in the high-frequency touch areaon the right side of the first interface when the terminal is held bythe right hand of the user, so that the user can operate the microphonemore conveniently and comfortably, and user experience can be improved.

This application further provides a communication method, and thecommunication method is applied to a terminal including a left antennaand a right antenna. The left antenna is disposed on a left part of theterminal, and the right antenna is disposed on a right part of theterminal. As shown in FIG. 20, the communication method includes S2001to S2003.

S2001. A terminal detects, in a voice communication process of theterminal, a current status of holding the terminal by a user.

The current status of holding the terminal by the user includes a stateof the terminal being held by a left hand or a state of the terminalbeing held by a right hand. For the method for determining, by theterminal, whether the terminal is held by the left hand of the user orheld by the right hand of the user, refer to related descriptions of theforegoing embodiment of this application. Details are not describedagain herein in this application.

S2002. The terminal increases transmit/receive power of the rightantenna of the terminal when the current status of holding the terminalby the user is the state of holding by the left hand.

S2003. The terminal increases transmit/receive power of the left antennaof the terminal when the current status of holding the terminal by theuser is the state of holding by the right hand.

In this application, the left side of the terminal is a sidecorresponding to the left hand of the user when a screen of the terminalis opposite to the user, and the right side of the terminal is a sidecorresponding to the right hand of the user when the screen of theterminal is opposite to the user. For example, as shown in FIG. 21, theterminal is a mobile phone 100. A left side of the mobile phone 100 maybe a part corresponding to a dashed-line block 2101, and a right side ofthe mobile phone 100 may be a part corresponding to a dashed-line block2102.

In this application, the left antenna of the terminal is an antennadisposed on the left side of the terminal, and the right antenna is anantenna disposed on the right side of the terminal. For example, asshown in FIG. 21, a left antenna of the mobile phone 100 may be disposedin the part corresponding to the dashed-line block 2101 in the mobilephone 100, and a right antenna of the mobile phone 100 may be disposedin the part corresponding to the dashed-line block 2102 in the mobilephone 100.

It may be conceived that the mobile phone 100 is used as an example ofthe terminal. In a voice communication process of the mobile phone 100,if the right hand of the user holds the mobile phone 100 in FIG. 21, theright side (the part corresponding to the dashed-line block 2102) of themobile phone 100 is closer to an ear of the user than the left side (thepart corresponding to the dashed-line block 2101) of the mobile phone100. In this case, because the right side of the mobile phone 100 isclose to the ear of the user, the right antenna of the mobile phone 100may suffer relatively great interference. In this case, using the methodin this application to increase transmit/receive power of the leftantenna of the mobile phone 100 may ensure that voice communicationquality of the mobile phone 100 is not affected.

Likewise, in a voice communication process of the mobile phone 100, ifthe left hand of the user holds the mobile phone 100, the left side (thepart corresponding to the dashed-line block 2101) of the mobile phone100 is closer to an ear of the user than the right side (the partcorresponding to the dashed-line block 2102) of the mobile phone 100. Inthis case, because the left side of the mobile phone 100 is close to theear of the user, the left antenna of the mobile phone 100 may sufferrelatively great interference. In this case, using the method in thisapplication to increase transmit/receive power of the right antenna ofthe mobile phone 100 may ensure that voice communication quality of themobile phone 100 is not affected.

In the communication method provided in this embodiment of thisapplication, in the voice communication process of the terminal, theterminal may determine the status of holding the terminal by the user;and when the status of holding the terminal by the user is the state ofholding by the left hand, considering that the left antenna may sufferrelatively great interference, to ensure that voice communicationquality of the terminal is not affected, the transmit/receive power ofthe right antenna may be increased; or when the current status ofholding the terminal by the user is the state of holding by the righthand, considering that the right antenna may suffer relatively greatinterference, to ensure that voice communication quality of the terminalis not affected, the transmit/receive power of the left antenna may beincreased.

Further, when the status of holding the terminal by the user is thestate of holding by the left hand, the left antenna may sufferrelatively great interference; or when the status of holding theterminal by the user is the state of holding by the right hand, theright antenna may suffer relatively great interference. Therefore, ifone antenna of the terminal suffers relatively great interference, toreduce power consumption of the terminal, the terminal may suppresstransmit/receive power of the antenna. Specifically, as shown in FIG.22, after S2001 shown in FIG. 20, the method in this application mayfurther include S2201 and S2202.

S2201. The terminal suppresses transmit/receive power of the leftantenna when the current status of holding the terminal by the user isthe state of holding by the left hand.

When the current status of holding the terminal by the user is the stateof holding by the left hand, the left antenna may suffer relativelygreat interference. To reduce power consumption of the terminal, theterminal may suppress the transmit/receive power of the left antenna.

S2202. The terminal suppresses transmit/receive power of the rightantenna when the current status of holding the terminal by the user isthe state of holding by the right hand.

When the current status of holding the terminal by the user is the stateof holding by the right hand, the right antenna may suffer relativelygreat interference. To reduce power consumption of the terminal, theterminal may suppress the transmit/receive power of the right antenna.

In this application, the terminal may increase transmit/receive power ofone antenna that suffers less interference, and suppresstransmit/receive power of the other antenna that suffers moreinterference. Therefore, power consumption of the terminal can bereduced while it is ensured that voice communication quality of theterminal is not affected.

Further, to improve efficiency of performing voice communication by theuser by using the terminal, the terminal may adjust volume of a leftvoice channel and volume of a right voice channel of the terminal basedon the status of holding the terminal by the user. Specifically, afterS2001, the method in this application may further include S2203 andS2204.

S2203. When the current status of holding the terminal by the user isthe state of holding the mobile phone by the left hand, the terminalturns up the volume of the left voice channel of the terminal.

If the current status of holding the terminal by the user is the stateof holding the mobile phone by the left hand, it indicates that the leftside of the terminal is closer to the ear of the user. To enable theuser to more clearly hear voice information transmitted from a peerdevice in the voice communication, the terminal may turn up the volumeof the left voice channel of the terminal.

S2204. When the current status of holding the terminal by the user isthe state of holding the mobile phone by the right hand, the terminalturns up the volume of the right voice channel of the terminal.

If the current status of holding the terminal by the user is the stateof holding the mobile phone by the right hand, it indicates that theright side of the terminal is closer to the ear of the user. To enablethe user to more clearly hear the voice information transmitted from thepeer device in the voice communication, the terminal may turn up thevolume of the right voice channel of the terminal.

Further, when the current status of holding the terminal by the user isthe state of holding the mobile phone by the left hand, the terminal mayturn down the volume of the right voice channel of the terminal; or whenthe current status of holding the terminal by the user is the state ofholding the mobile phone by the right hand, the terminal may turn downthe volume of the left voice channel of the terminal. Therefore, adverseimpact of the voice information transmitted from the peer device onother users in the voice communication process of the terminal can bereduced, and a possibility of hearing content of the voice communicationby the other users can be further reduced. This helps protect privacy ofthe user.

In this application, the terminal may further adjust the volume of theleft voice channel and the volume of the right voice channel of theterminal based on the status of holding the terminal by the user, sothat the user can more clearly hear the voice information transmitted bythe peer device in the voice communication. Therefore, an effect of thevoice communication can be enhanced. In addition, the possibility ofhearing the content of the voice communication by the other users can befurther reduced. This helps protect privacy of the user.

This application further provides a display method, and the displaymethod may be applied to a terminal including one or more sensors. Theone or more sensors are configured to detect a motion status of theterminal. The display method includes: a terminal detects a motionparameter of the terminal by using a sensor, and displays an interfaceof a fitness application when the detected motion parameter indicatesthat the terminal is in a fitness state of a user. The motion parameterincludes at least a parameter captured by the sensor when the user doesexercises, such as a parameter captured by the sensor when the userruns, a parameter captured by the sensor when four limbs of the usermove or when the user twists the waist, or a parameter captured by thesensor when the user bounces.

It may be understood that, no matter which interface the terminalcurrently displays, such as the interface 303 of the “Browser”application shown in (a-2) in FIG. 4B, the home screen 1801 including aplurality of application icons as shown in (a-2) in FIG. 18B, thescreen-off state shown in FIG. 19, or the locked-screen interface 301shown in FIG. 3A, when the sensor captures the foregoing motionparameter, the terminal may display the interface of the fitnessapplication, so that the user can operate the terminal on the interfaceof the fitness application, and the terminal records motion data of theuser in the fitness application. Certainly, when the terminal capturesthe foregoing motion parameter, the terminal may not display theinterface of the fitness application, but directly records the motiondata of the user in the fitness application.

For example, it is assumed that when the user walks or stands still asshown in (a-1) in FIG. 23, a mobile phone 100 displays a locked-screeninterface 2301 shown in (a-2) in FIG. 23. When the user starts to run asshown in (b-1) in FIG. 23, a sensor in the mobile phone 100 may capturethe motion parameter when the user runs. In this case, the mobile phone100 may search for all applications that are installed in the mobilephone 100 and whose application attributes are sport or fitness orhealth, and present a search result to the user, for example, display aninterface 2302 of the fitness application shown in (b-2) in FIG. 23.Optionally, the interface 2302 of the fitness application includes aplurality of sports items, such as “running”, “cycling”, and “mountainclimbing”. The user may select, from the plurality of sports items, asports item corresponding to a current sport of the user, so that theterminal can record corresponding motion data in the fitnessapplication. Optionally, the terminal may also first search forapplications that are already enabled or applications that are inrunning states and whose attributes are sport-related, for example,sport/fitness/shaping/health, and present found applications; or afterno started sport-related application is found, may search forsport-related applications installed in the terminal; or may search forall sport-related applications installed in the terminal, and arrange astarted application in a first position.

In the display method provided in this application, the terminal maydetect the motion parameter of the terminal by using the sensor, and maydisplay the interface of the fitness application when the detectedmotion parameter indicates that the terminal is in the fitness state ofthe user. The interface of the fitness application can be opened withoutrequiring excessive user operations. In this application, afterdetecting the motion parameter of the terminal, the terminal mayautomatically search for all applications that are already installed inthe terminal and whose attributes are fitness or sport, and display theapplications on a screen, that is, display the interface of the fitnessapplication. Therefore, the user can operate the terminal on theinterface of the fitness application, so that the terminal records themotion data of the user in the fitness application. This improvesman-machine interaction performance, improves operation efficiency, andfurther improves user experience.

It may be understood that, to implement the foregoing functions, theterminal includes corresponding hardware structures and/or softwaremodules for performing the functions. A person skilled in the art shouldeasily be aware that, in combination with the examples described in theembodiments disclosed in this specification, units and algorithm stepsmay be implemented by hardware or a combination of hardware and computersoftware. Whether a function is performed by hardware or hardware drivenby computer software depends on particular applications and designconstraints of the technical solutions. A person skilled in the art mayuse different methods to implement the described functions for eachparticular application, but it should not be considered that theimplementation goes beyond the scope of the embodiments of the presentinvention.

In the embodiments of this application, functional modules in theterminal or the like may be defined according to the foregoing methodexamples. For example, each functional module may be defined in acorrespondence to each function, or two or more functions may beintegrated in one processing module. The integrated module may beimplemented in a form of hardware, or may be implemented in a form of asoftware functional module. It should be noted that, in the embodimentsof the present invention, module division is an example, and is merelylogical function division. In actual implementation, another divisionmanner may be used.

When each functional module is defined in a correspondence to eachfunction, as shown in FIG. 24, an embodiment of this applicationprovides a terminal 2400. The terminal 2400 includes a detection unit2401 and a display unit 2402.

The detection unit 2401 is configured to support the terminal inperforming S201 in the foregoing method embodiment, and/or is used inother processes of the technology described in this specification. Thedisplay unit 2402 is configured to support the terminal in performingS202, S203, S601, S202 a, and S1401 in the foregoing method embodiments,and/or is used in other processes of the technology described in thisspecification.

Further, the terminal 2400 may further include a turn-on unit. Theturn-on unit is configured to support the terminal in performing S901 inthe foregoing method embodiment, and/or is used in other processes ofthe technology described in this specification.

Further, the terminal 2400 may further include a storage unit. Thestorage unit is configured to support the terminal in performing S902and S1201 in the foregoing method embodiments, and/or is used in otherprocesses of the technology described in this specification.

Certainly, the terminal 2400 includes but is not limited to the unitsand modules illustrated above. For example, the terminal 2400 mayfurther include a communications unit, and the communications unit isconfigured to communicate with another terminal. In addition, functionsthat the functional units can specifically implement include but are notlimited to the functions corresponding to the method steps in theforegoing examples. For detailed descriptions about other units of theterminal 2400, refer to the detailed descriptions about the method stepscorresponding to the units. Details are not described again herein inthis embodiment of this application.

When an integrated unit is used, the detection unit 2401, the turn-onunit, and the like may be integrated in a processing module forimplementation; the communications unit may be an RF circuit, a Wi-Fimodule, or a Bluetooth module of the terminal; the storage unit may be astorage module of the terminal; and the display unit 2402 may be adisplay module, for example, a touchscreen.

FIG. 25 is a possible schematic structural diagram of a terminal in theforegoing embodiment. The terminal 2500 includes a processing module2501, a storage module 2502, a display module 2503, a sensing module2504, and an image capture module 2505. The sensing module 2504 isconfigured to detect a status of holding the terminal by a user. Theprocessing module 2501 is configured to control and manage the terminalbased on information detected by the sensing module 2504. The displaymodule 2503 is configured to display an image generated by theprocessing module 2501. The storage module 2502 is configured to storeprogram code and data of the terminal. The image capture module 2505 isconfigured to capture an image.

Further, the terminal 2500 may further include a communications module.The communications module is configured to communicate with anotherterminal. For example, the communications module is configured toperform voice communication with another terminal, and receive a profilepicture from or send a profile picture to the another terminal.

The processing module 2501 may be a processor or a controller, forexample, may be a central processing unit (Central Processing Unit,CPU), a general-purpose processor, a digital signal processor (DigitalSignal Processor, DSP), an application-specific integrated circuit(Application-Specific Integrated Circuit, ASIC), a field programmablegate array (Field Programmable Gate Array, FPGA) or another programmablelogic device, a transistor logic device, a hardware component, or anycombination thereof. The controller/processor may implement or executevarious example logical blocks, modules, and circuits described withreference to content disclosed in the present invention. Alternatively,the processor may be a combination of processors implementing acomputing function, for example, a combination of one or moremicroprocessors, or a combination of the DSP and a microprocessor. Thecommunications module may be a transceiver, a transceiver circuit, acommunications interface, or the like. The storage module 2502 may be amemory. The sensing module 2504 may be a sensor. The image capturemodule 2505 may be a camera.

When the processing module 2501 is a processor (such as the processor501 shown in FIG. 5), and the communications module is an RF circuit(such as the radio frequency circuit 502 shown in FIG. 5), and thestorage module 2502 is a memory (such as the memory 103 shown in FIG.1), and the display module 2503 is a touchscreen (including the touchpad104-1 and the display 104-2 shown in FIG. 1), and the sensing module2504 is a sensor (such as the sensor 106 shown in FIG. 1), the terminalprovided in this application may be the mobile phone 100 shown inFIG. 1. The communications modules may include not only the RF circuit,but also the Wi-Fi module and the Bluetooth module. The communicationsmodules such as the RF circuit, the Wi-Fi module, and the Bluetoothmodule may be collectively referred to as a communications interface.The processor, the communications interface, the touchscreen, and thememory may be coupled together by using a bus.

When each functional module is defined in a correspondence to eachfunction, as shown in FIG. 26, an embodiment of this applicationprovides a terminal. The terminal 2600 includes a microphone and asensor. The terminal 2600 further includes a detection unit 2601, adisplay unit 2602, and a turn-on unit 2603.

The detection unit 2601 is configured to support the terminal inperforming S1701 in the foregoing method embodiment, and/or is used inother processes of the technology described in this specification. Thedisplay unit 2602 is configured to support the terminal in performingS1702 and S1702 a in the foregoing method embodiment, and/or is used inother processes of the technology described in this specification. Theturn-on unit 2603 is configured to support the terminal in performingS1703 in the foregoing method embodiment, and/or is used in otherprocesses of the technology described in this specification.

Certainly, the terminal 2600 includes but is not limited to the unitsand modules illustrated above. For example, the terminal 2600 mayfurther include a communications unit, and the communications unit isconfigured to communicate with another terminal. In addition, functionsthat the functional units can specifically implement include but are notlimited to the functions corresponding to the method steps in theforegoing examples. For detailed descriptions about other units of theterminal 2600, refer to the detailed descriptions about the method stepscorresponding to the units. Details are not described again herein inthis embodiment of this application.

When an integrated unit is used, the detection unit 2601, the turn-onunit 2603, and the like may be integrated in a processing module forimplementation; the communications unit may be an RF circuit, a Wi-Fimodule, or a Bluetooth module of the terminal; the storage unit may be astorage module of the terminal; and the display unit 2602 may be adisplay module, for example, a touchscreen. FIG. 25 is a possibleschematic structural diagram of a terminal in the foregoing embodiment.The terminal 2500 shown in FIG. 25 is not described in detail againherein in this embodiment of this application. It should be noted that,the terminal in this embodiment further includes a voice data capturemodule, and the voice data capture module may be the microphone in FIG.1.

When each functional module is defined in a correspondence to eachfunction, an embodiment of this application provides a terminal. Theterminal includes a left antenna and a right antenna, the left antennais disposed on a left part of the terminal, and the right antenna isdisposed on a right part of the terminal. The terminal further includesa communications unit and a processing unit.

The communications unit is configured to support the terminal inperforming voice communication, and/or is used in other processes of thetechnology described in this specification. The processing unit isconfigured to support the terminal in performing S2001 to S2003, S2201and S2202, and S2203 and S2204 in the foregoing method embodiments,and/or is used in other processes of the technology described in thisspecification.

Certainly, the terminal includes but is not limited to the units andmodules illustrated above. For example, the terminal may further includea display unit, and the display unit is configured to display an imagegenerated by the processing unit. In addition, functions that thefunctional units can specifically implement include but are not limitedto the functions corresponding to the method steps in the foregoingexamples. For detailed descriptions about other units of the terminal,refer to the detailed descriptions about the method steps correspondingto the units. Details are not described again herein in this embodimentof this application.

When an integrated unit is used, the processing unit may be integratedin a processing module for implementation; the communications unit maybe an RF circuit, a Wi-Fi module, or a Bluetooth module of the terminal;the storage unit may be a storage module of the terminal; and thedisplay unit may be a display module, for example, a display (alsoreferred to as a touchscreen in this application). FIG. 25 is a possibleschematic structural diagram of a terminal in the foregoing embodiment.The terminal 2500 shown in FIG. 25 is not described in detail againherein in this embodiment of this application.

An embodiment of this application further provides a computer storagemedium, and the computer storage medium stores computer program code.When the foregoing processor executes the computer program code, theterminal performs related method steps in any one of FIG. 2, FIG. 6,FIG. 9, FIG. 12, FIG. 14, FIG. 17, FIG. 20, and FIG. 22, to implementthe methods in the foregoing embodiments.

An embodiment of this application further provides a computer programproduct, and when the computer program product is run on a computer, thecomputer is enabled to perform related method steps in any one of FIG.2, FIG. 6, FIG. 9, FIG. 12, FIG. 14, FIG. 17, FIG. 20, and FIG. 22, toimplement the methods in the foregoing embodiments.

The terminal 2400, the terminal 2500, the terminal 2600, the computerstorage medium, and the computer program product provided in thisapplication are all configured to perform the corresponding methodsprovided above. Therefore, for beneficial effects that the terminals,the computer storage medium, and the computer program product canachieve, refer to beneficial effects in the corresponding methodsprovided above. Details are not described again herein.

The foregoing descriptions about implementations allow a person skilledin the art to clearly understand that, for the purpose of convenient andbrief description, division of the foregoing functional modules is usedonly as an example for illustration. In actual application, theforegoing functions can be allocated to different modules andimplemented based on a requirement, that is, an internal structure of anapparatus is divided into different functional modules to implement allor some of the functions described above. For a detailed working processof the foregoing system, apparatus, and unit, refer to a correspondingprocess in the foregoing method embodiments, and details are notdescribed again herein.

In the several embodiments provided in this application, it should beunderstood that the disclosed system, apparatus, and method may beimplemented in other manners. For example, the described apparatusembodiment is merely an example. For example, the module or unitdivision is merely logical function division and may be other divisionin actual implementation. For example, a plurality of units orcomponents may be combined or integrated into another system, or somefeatures may be ignored or may not be performed. In addition, thedisplayed or discussed mutual couplings or direct couplings orcommunication connections may be implemented by using some interfaces.The indirect couplings or communication connections between theapparatuses or units may be implemented in electronic, mechanical, orother forms.

The units described as separate parts may or may not be physicallyseparate, and parts displayed as units may or may not be physical units,may be located in one position, or may be distributed on a plurality ofnetwork units. Some or all of the units may be selected based on actualrequirements to achieve the objectives of the solutions of theembodiments.

In addition, functional units in the embodiments of this application maybe integrated into one processing unit, or each of the units may existalone physically, or two or more units may be integrated into one unit.The integrated unit may be implemented in a form of hardware, or may beimplemented in a form of a software functional unit.

When the integrated unit is implemented in the form of a softwarefunctional unit and sold or used as an independent product, theintegrated unit may be stored in a computer-readable storage medium.Based on such an understanding, the technical solutions of thisapplication essentially, or the part contributing to the prior art, orall or some of the technical solutions may be implemented in a form of acomputer software product. The computer software product is stored in astorage medium and includes several instructions for instructing acomputer device (which may be a personal computer, a server, a networkdevice, or the like) to perform all or some of the steps of the methodsdescribed in the embodiments of this application. The storage mediumincludes any medium that can store program code, such as a flash memory,a removable hard disk, a read-only memory, a random access memory, amagnetic disk, or an optical disc.

The foregoing descriptions are merely specific implementations of thisapplication, but are not intended to limit the protection scope of thisapplication. Any variation or replacement readily figured out by aperson skilled in the art within the technical scope disclosed in thisapplication shall fall within the protection scope of this application.Therefore, the protection scope of this application shall be subject tothe protection scope of the claims.

1.-26. (canceled)
 27. A terminal, comprising: a processor; one or moresensors coupled to the processor and configured to detect a status ofholding the terminal by a user; and a memory coupled to the processorand storing instructions that, when executed by the processor, cause theterminal to be configured to: display a first interface with a firstphotographing control in response to detecting that a current status ofholding the terminal by the user has undergone a change satisfying apreset condition, wherein the first interface is not a viewfinderinterface of the terminal; and display a second interface in response toan operation of the user on the first photographing control, wherein thesecond interface is the viewfinder interface.
 28. The terminal of claim27, further comprising a camera, wherein the instructions further causethe terminal to be configured to turn on the camera in response to theone or more sensors detecting that the current status of holding theterminal has undergone the change satisfying the preset condition tocapture a preview image using the camera.
 29. The terminal of claim 28,wherein the instructions further cause the terminal to be configured tosave a first image that is based on the preview image in response to afirst operation of the user on the first photographing control.
 30. Theterminal of claim 27, further comprising a touchscreen, wherein the oneor more sensors is configured to detect that the terminal has rotatedand moved upward, and wherein the preset condition comprises an includedangle between the touchscreen and a horizontal screen is within a presetrange after the one or more sensors detect that the terminal has rotatedand moved upward.
 31. The terminal of claim 27, further comprising atouchscreen, wherein the instructions further cause the terminal to beconfigured to instruct the touchscreen to display the viewfinderinterface in a photographing mode in response to a second operation ofthe user on the first photographing control, and wherein thephotographing mode is a photographing mode using a rear-facing camera, aself-photographing mode, a panoramic mode, or a video recording mode.32. The terminal of claim 27, further comprising a camera, wherein thesecond interface comprises a second photographing control, and whereinafter the instructions cause the terminal to display the secondinterface, the instructions further cause the terminal to save, inresponse to a third operation of the user on the second photographingcontrol, an image captured by the camera in response to the thirdoperation.
 33. The terminal of claim 32, wherein after the instructionscause the terminal to display the second interface, the instructionsfurther cause the terminal to display a third interface in response to afourth operation of the user on the second photographing control,wherein the fourth operation instructs the terminal to switch betweenphotographing modes of the terminal, wherein the third interface is theviewfinder interface in a photographing mode corresponding to the fourthoperation, and wherein the fourth operation is different from the thirdoperation.
 34. The terminal of claim 32, further comprising atouchscreen, and wherein display positions of the first photographingcontrol and the second photographing control on the touchscreen are thesame.
 35. The terminal of claim 27, wherein the instructions cause theterminal to display the first photographing control on the firstinterface by displaying, in a floating manner, the first photographingcontrol on the first interface.
 36. The terminal of claim 35, whereinthe one or more sensors detects no operation on the first photographingcontrol unit within a preset time after the first photographing controlis displayed on the first interface in the floating manner, and whereinthe instructions further cause the terminal to no longer display thefirst photographing control on the first interface when the one or moresensors detect no operation on the first photographing control withinthe preset time after the first photographing control is displayed onthe first interface in the floating manner.
 37. The terminal of claim35, wherein the one or more sensors are further configured to detectwhether the terminal is currently being held by a left hand of the useror by a right hand of the user, and wherein the instructions furthercause the terminal to: display the first photographing control on a leftside of the first interface in the floating manner when the terminal iscurrently being held by the left hand; and display the firstphotographing control on a right side of the first interface in thefloating manner when the terminal is currently being held by the righthand.
 38. The terminal of claim 27, further comprising a camera, andwherein before displaying the first photographing control on the firstinterface, the one or more sensors are further configured to detect thatthe camera is in an off state.
 39. A terminal, comprising: a processor;a touchscreen coupled to the processor and configured to performdisplaying according to an instruction of the processor; one or moresensors coupled to the processor; and a memory coupled to the processorand storing instructions that, when executed by the processor, cause theterminal to be configured to: detect a user operation in a screen-offstate of the terminal; light the touchscreen and display a firstinterface when the user operation is an operation of lighting thetouchscreen; display a second interface that is different from the firstinterface when the user operation is a first gesture, wherein the firstgesture indicates that a current status of holding the terminal by auser has undergone a change satisfying a preset condition, wherein thefirst gesture is different from the operation of lighting thetouchscreen, wherein the second interface displays a first photographingcontrol, and wherein the second interface is not a viewfinder interfaceof the terminal; and display the viewfinder interface of the terminal inresponse to an operation of the user on the first photographing control.40.-49. (canceled)
 50. A terminal, comprising: a processor; a microphonecoupled to the processor; one or more sensors coupled to the processorand configured to detect a status of holding the terminal by a user; atouchscreen coupled to the processor and configured to display amicrophone control in a microphone-off state of the terminal in responseto the one or more sensors detecting that a current status of holdingthe terminal by the user has undergone a change satisfying a presetcondition; and a memory coupled to the processor and storinginstructions that, when executed by the processor, cause the terminal tobe configured to turn on the microphone in response to an operation ofthe user on the microphone control.
 51. The terminal of claim 50,wherein the touchscreen is further configured to display the microphonecontrol in a floating manner.
 52. The terminal of claim 50, wherein thetouchscreen is further configured to: display the microphone control ina high-frequency touch area on a left side of the touchscreen of theterminal in response to the one or more sensors detecting that theterminal is held by a left hand of the user; or display the microphonecontrol in a high-frequency touch area on a right side of thetouchscreen of the terminal in response to the one or more sensorsdetecting that the terminal is held by a right hand of the user.
 53. Theterminal of claim 50, wherein the preset condition comprises an includedangle between the touchscreen of the terminal and a horizontal line iswithin a preset range after the one or more sensors detect that theterminal is rotated and moves upward.
 54. The terminal of claim 50,wherein the processor is configured to turn on the microphone by turningon the microphone in response to the operation of the user on themicrophone control and enabling a speech recognition function. 55.-59.(canceled)
 60. The terminal of claim 50, wherein the touchscreen isfurther configured to display the microphone control in a high-frequencytouch area of the touchscreen.
 61. The terminal of claim 35, wherein theone or more sensors are further configured to detect that the terminalis currently held by a left hand of the user or by a right hand of theuser.